Changeset 6975
- Timestamp:
- Oct 8, 2015, 8:11:11 AM (7 years ago)
- Location:
- branches/3.6-stable
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/3.6-stable/doc/src/docbook/user/annotations.xml
r6961 r6975 807 807 </para> 808 808 809 <para> 810 Use the <guibutton>Inherit</guibutton> button to inherit the selected 811 annotations by reference, and the <guibutton>Clone</guibutton> button 812 to clone the values of the selected annotations. 813 </para> 814 809 815 <note> 810 816 <itemizedlist> 811 817 <listitem> 812 818 <para> 813 Already inherited annotations are not shown in the dialog. 814 </para> 815 </listitem> 816 <listitem> 817 <para> 818 By default, the inheritance is implemented by reference. To convert 819 it to a cloned annotation select it in the list and click on <guilabel>clone</guilabel>. 819 Already inherited or cloned annotations are not shown in the dialog. 820 </para> 821 </listitem> 822 <listitem> 823 <para> 824 Annotations that are inherited by reference can easily be converted to 825 cloned annotations. Select the annotation in the list and click on the 826 <guilabel>clone</guilabel> link. 820 827 <nohelp> 821 828 <figure> … … 831 838 </figure> 832 839 </nohelp> 833 834 840 </para> 835 841 </listitem> -
branches/3.6-stable/www/common/annotations/annotate.js
r6974 r6975 981 981 Doc.show('inherited-list'); 982 982 var inheritedId = event.detail.id; 983 var clone = event.detail.clone; 983 984 984 985 // Check if we have info about this annotation already … … 989 990 { 990 991 entry.modified = INHERITED; 992 if (clone && entry.source != 'CLONED') 993 { 994 annotate.convertToCloned(entry); 995 } 996 else if (!clone && entry.source != 'INHERITED') 997 { 998 annotate.convertToInherited(entry); 999 } 991 1000 Doc.show(entry.id); 992 1001 return; … … 1002 1011 request.open("GET", url, true); 1003 1012 request.send(null); 1004 Ajax.setReadyStateHandler(request, annotate.inheritInfoLoaded, annotate.inheritInfoLoaded); 1013 var callback = clone ? annotate.inheritInfoLoadedAndClone : annotate.inheritInfoLoaded; 1014 Ajax.setReadyStateHandler(request, callback, callback); 1015 } 1016 1017 /** 1018 Callback that converts the inherited annotation to a cloned 1019 annotation. 1020 */ 1021 annotate.inheritInfoLoadedAndClone = function(request) 1022 { 1023 var entry = annotate.inheritInfoLoaded(request); 1024 annotate.convertToCloned(entry); 1005 1025 } 1006 1026 … … 1023 1043 annotations[annotations.length] = entry; 1024 1044 annotate.createAnnotationEntryInList(entry, true); 1045 return entry; 1025 1046 } 1026 1047 -
branches/3.6-stable/www/common/annotations/inherit.js
r6947 r6975 32 32 // Buttons (on standalone dialog) 33 33 Buttons.addClickHandler('close', App.closeWindow); 34 Buttons.addClickHandler('btnOk', inherit.save); 34 Buttons.addClickHandler('btnInherit', inherit.save); 35 Buttons.addClickHandler('btnClone', inherit.save); 35 36 36 37 Events.addEventHandler('quickFilter', 'keyup', inherit.quickFilter); … … 80 81 } 81 82 82 inherit.saveInheritedAnnotations = function( )83 inherit.saveInheritedAnnotations = function(clone) 83 84 { 84 85 var tree = Doc.element('joust'); … … 100 101 var detail = {}; 101 102 detail.id = menuItem.externalId; 103 detail.clone = clone; 102 104 if (isInherited) 103 105 { … … 140 142 Save the annotations in standalone mode. 141 143 */ 142 inherit.save = function( )144 inherit.save = function(event) 143 145 { 144 inherit.saveInheritedAnnotations(); 146 var clone = Data.int(event.currentTarget, 'clone', 0); 147 inherit.saveInheritedAnnotations(clone); 145 148 App.closeWindow(); 146 149 } -
branches/3.6-stable/www/common/annotations/inherit.jsp
r6947 r6975 371 371 372 372 <base:buttongroup subclass="dialogbuttons"> 373 <base:button id="btnOk" title="Ok" /> 373 <base:button id="btnClone" title="Clone" image="copy.png" data-clone="1" /> 374 <base:button id="btnInherit" title="Inherit" image="inherit.png" /> 374 375 <base:button id="close" title="Cancel" /> 375 376 </base:buttongroup>
Note: See TracChangeset
for help on using the changeset viewer.