|
|
|
Re: Is it possible to use TabbedPropertySheetPage with UndoablePropertySheetEntry [message #226915 is a reply to message #226888] |
Sun, 26 November 2006 02:57 |
Eclipse User |
|
|
|
Originally posted by: caomin2005.gmail.com
Alex,
I got CommandStack through getPart().getAdapter(Class) in my PropertySection
class, and let CommandStack to execute local command for any changes, so my
editor can undo/redo for changes from PropertyView.
I will try UndoablePropertySheetEntry later.
Thanks
Michael
"Alex Boyko" <aboyko@ca.ibm.com> wrote in message
news:a3650e1ad1c3ca085b8335cd67f69dca$1@www.eclipse.org...
> Hi Michael,
>
> UndoablePropertySheetEntry is exactly what has to be used, they do support
> undo/redo functionality.
> However, you should be able to get that functionality almost for free if
> you subclass GEF's GraphicalEditor class by your editor (Your model
> elements should implement IPropertySource). Otherwise, use GraphicalEditor
> as a reference, properties view for the editor is set up in
> getAdapter(Class) method.
>
> Cheers,
> Alex
>
|
|
|
Re: Is it possible to use TabbedPropertySheetPage with UndoablePropertySheetEntry [message #226922 is a reply to message #226882] |
Sun, 26 November 2006 03:20 |
Eclipse User |
|
|
|
Originally posted by: caomin2005.gmail.com
Anthony,
In my propertySections for TabbedPropertySheetPage, I construct a command
for any changes, and then get CommandStack through
getPart().getAdapater(Class0,
and let CommandStack to execute my command. this way, any changes made in
property view can be undoable.
Thanks,
Michael
"Anthony Hunter" <anthonyh@ca.ibm.com> wrote in message
news:ek7nq5$avr$1@utils.eclipse.org...
> Hi Michael
>
> The best way to get undo and redo to work in the properties view is to
> retarget the global actions to that of your editor. This way undo/redo for
> the view(s) match that of your editor.
>
> In fact, TabbedPropertySheetPage.setActionBars() is supposed to do that
> for you, you will need to debug here to see what is going on.
>
> Cheers...
> Anthony
>
> "michael cao" <caomin2005@gmail.com> wrote in message
> news:ek1pfq$6uj$1@utils.eclipse.org...
>> Hi,
>>
>> I hope to implement undo/redo functions in a TabbedPropertySheetPage
>> page. can UndoablePropertySheetEntry be used here ?, I am total lost
>> here, Could someone help on this ?
>>
>> Thanks,
>> Michael
>>
>
>
|
|
|
Powered by
FUDForum. Page generated in 0.03711 seconds