Line | |
---|
1 | package clarin.cmdi.componentregistry.common.components |
---|
2 | { |
---|
3 | import clarin.cmdi.componentregistry.common.RssLinkPopUp; |
---|
4 | import clarin.cmdi.componentregistry.common.ItemDescription; |
---|
5 | import clarin.cmdi.componentregistry.services.Config; |
---|
6 | |
---|
7 | import flash.geom.Point; |
---|
8 | import flash.events.ContextMenuEvent; |
---|
9 | import mx.managers.PopUpManager; |
---|
10 | import flash.system.System; |
---|
11 | |
---|
12 | public class RssCommentsContextMenu extends RssContextMenu |
---|
13 | { |
---|
14 | private var _itemDescription:ItemDescription; |
---|
15 | |
---|
16 | public function RssCommentsContextMenu(itemDescription:ItemDescription) |
---|
17 | { super(); |
---|
18 | _itemDescription = itemDescription; |
---|
19 | } |
---|
20 | |
---|
21 | |
---|
22 | override protected function copyRssLink(event:ContextMenuEvent):void { |
---|
23 | System.setClipboard(Config.getRssUriComments(_itemDescription)); |
---|
24 | } |
---|
25 | |
---|
26 | |
---|
27 | override protected function showRssLink(event:ContextMenuEvent):void{ |
---|
28 | |
---|
29 | var rssLinkPanel:RssLinkPopUp = new RssLinkPopUp(); |
---|
30 | rssLinkPanel.uri=Config.getRssUriComments(_itemDescription); |
---|
31 | |
---|
32 | var xShift:int = 0; |
---|
33 | var position:Point = positioning(xShift, event); |
---|
34 | rssLinkPanel.x = position.x; |
---|
35 | rssLinkPanel.y= position.y; |
---|
36 | |
---|
37 | PopUpManager.addPopUp(rssLinkPanel, event.mouseTarget); |
---|
38 | } |
---|
39 | } |
---|
40 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.