Changeset 2080 for ComponentRegistry/branches/ComponentRegistry-1.12.0/ComponentBrowserGui/src/main/flex/clarin/cmdi/componentregistry/editor/EditorAS.as
- Timestamp:
- 08/14/12 13:20:19 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
ComponentRegistry/branches/ComponentRegistry-1.12.0/ComponentBrowserGui/src/main/flex/clarin/cmdi/componentregistry/editor/EditorAS.as
r1988 r2080 2 2 import clarin.cmdi.componentregistry.browser.BrowserColumns; 3 3 import clarin.cmdi.componentregistry.common.ItemDescription; 4 import clarin.cmdi.componentregistry.common.components.RegistryViewStack; 4 5 import clarin.cmdi.componentregistry.editor.model.CMDModelFactory; 5 6 import clarin.cmdi.componentregistry.editor.model.CMDSpec; … … 39 40 private var uploadService:UploadService = new UploadService(); 40 41 42 [Bindable] 43 private var viewStack:RegistryViewStack; 41 44 42 45 public function init():void { … … 47 50 uploadService.init(uploadProgress); 48 51 Config.instance.addEventListener(Config.USER_SPACE_TOGGLE_EVENT, toggleUserSpace); 52 viewStack = this.parent as RegistryViewStack; 49 53 } 50 54 … … 131 135 } 132 136 137 private function cancel():void { 138 Alert.show("Are you sure you want to cancel editing?", "Cancel editing", Alert.YES|Alert.NO, null, 139 function (eventObj:CloseEvent):void{ 140 if(eventObj.detail == Alert.YES){ 141 viewStack.switchToBrowse(itemDescription); 142 } 143 }); 144 } 145 133 146 /** 134 147 * Calls usage check for the specified component. If in use, asks user whether to proceed; if positive, initiates update.
Note: See TracChangeset
for help on using the changeset viewer.