History log of /haiku/src/apps/diskprobe/DataEditor.h
Revision Date Author Comments
# e85413ad 02-Nov-2018 Axel Dörfler <axeld@pinc-software.de>

DiskProbe: Coding style cleanup

* Not complete, no functional changes intended.


# 6c85c7ee 14-Aug-2009 Philippe Saint-Pierre <stpere@gmail.com>

Revert r32402. Some problems are occuring in the attribute editor and I want to make sure they aren't caused by my patch before committing for good.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32409 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 498c03bd 14-Aug-2009 Philippe Saint-Pierre <stpere@gmail.com>

StringEditor : The TextView wasn't sending messages saying its content was modified by the user.
Symptoms :
* The Save menu item wasn't enabled
* the undo/redo menu item weren't neither

The fix I made was to commit the changes made by the user to the editor instance, by augmenting the InsertText and DeleteText from the TextView.
This fixes ticket #3507.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32402 a95241bf-73f2-0310-859d-f6bbb57e9c96


# f6e4cbb9 15-Oct-2007 Axel Dörfler <axeld@pinc-software.de>

* Rewrote BeBuild.h which had "a few" consequences (got rid of all those class
definitions).
* Minor cleanup here and there.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22577 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 6f850dfd 26-Mar-2006 Axel Dörfler <axeld@pinc-software.de>

Build fixes for the R5/Dano target, no longer relies on the COMPILE_FOR_R5 macro.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16887 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 9e98ea36 17-Dec-2004 Axel Dörfler <axeld@pinc-software.de>

The DataEditor now has a separate entry_ref for attributes - that's used
to have access to the attributes of a root directory. Internally, only
this ref is used when accessing attribute data.
Also fixed an initialization bug in case the stream couldn't be properly
opened; some values were just set too late (could lead to strange things
as well as a crash).


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10481 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 0283ecc0 29-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

Implemented case insensitive search. It's now available in hex mode as well.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6822 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 8db24919 27-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

Implemented find functionality. The find panel is still missing though, it
just searches for "test".
The find itself is implemented in DataEditor::Find() which sets the editor
in read-only mode and searches for the specified data. It will update a
progress monitor, it will find data no matter if it's on a view size break,
and it is interruptible at any time.
The DataEditor change methods now respect the read-only mode, and return
B_NOT_ALLOWED in this case.
Renamed the UpdateLooper class to EditorLooper class, since it now also
runs the find action.
The ProbeView class now maintains the "Find Again" menu item; it's target
message always contains the item that last searched for.
The HeaderView will now show a "Stop" button while the search operation
is in progress; it also acts as the Find() progress monitor.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6789 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a7511f36 26-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

Implemented changing the block size - that caused several changes to
DataEditor::SetViewSize()/SetViewOffset() because they did not correctly
update some values under certain circumstances.
There is now a kMsgDataEditorParameterChange instead of just ...OffsetChange;
the message will contain information about what has changed exactly.
Added a new kDataViewPreferredSize notifier that indicates a change of
the preferred size of the DataView. The ProbeView now listens to that
instead of knowing when to update the window limits.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6772 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a4ce63bf 26-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

Implemented Save() functionality. ApplyChanges() can now create the editor
version of the file from any state.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6763 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c65f61d4 26-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

Added a StateWatcher class that will automatically send notices for
all changed states during the lifetime of the object upon destruction.
Added some comments.
Uncommented the IsModified() method (does not yet work correctly, though).


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6760 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 707aa753 25-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

Removed DataEditor::SetToAttribute() method.
DataEditor::InitCheck() is now properly working for all types.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6747 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 66fcb84e 24-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

Now maintains the undo/redo state watcher, and also the data update
containing the range of affected bytes.
Added missing initialization of fLastChange and fFirstChange.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6733 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 32069a88 24-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

Made the attribute type accessible read-only.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6711 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 84a09d60 23-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

No longer takes an attribute for a file, or a device for an attribute.
Implemented attribute support.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6709 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 053bb738 23-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

Added a UpdateIfNeeded() method that you can call when you are not
interested in the data at all.
No longer imitates the BHandler observer model, but directly send
its update messages to the observers.
Now also stores the entry_ref of the file/device in the editor.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6704 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 60299214 18-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

Implemented proper focus handling in DataView instead of forcing focus
whenever the window got activated.
New DataView::MakeVisible() makes sure the specified position is visible
in the view, and scrolls to it if not (both, horizontally and vertically).
Implemented cursor navigation and selection extension in the DataView class.
Fixed a bug in DataView::SetSelection() that could let slip through invalid
values.
Renamed DataEditor observer notices.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6634 a95241bf-73f2-0310-859d-f6bbb57e9c96


# f7efc8f4 17-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

The DataEditor class is now subclasses from BLocker instead of aggregating
it. This way, it can directly be used in the BAutolock class, and also provides
some more sophisticated locking functions.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6621 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 8b6c387e 12-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

Fixed the wrong return type of ViewSize().
Reduced the number of state message types.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6570 a95241bf-73f2-0310-859d-f6bbb57e9c96


# f748e2d4 11-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

Extended watching mechanism (it now works more like the BHandler watching
mechanism) - it's not really used yet, though.
Fixed some variable initialization bugs and missing return values.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6566 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1df68d1d 15-Jan-2004 Axel Dörfler <axeld@pinc-software.de>

Started to work on a DiskProbe replacement as a side project.
Implemented the basic editor engine that has features like undo/redo
and everything else DiskProbe could possibly need - not complete yet,
though it already has everything that would be needed for a 1:1 DiskProbe
duplicate.
The DiskProbe app is currently just a small text based test for that engine.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6096 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 6c85c7eec82f314274e41ca842f7c9dc8f35d3c3 14-Aug-2009 Philippe Saint-Pierre <stpere@gmail.com>

Revert r32402. Some problems are occuring in the attribute editor and I want to make sure they aren't caused by my patch before committing for good.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32409 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 498c03bdd66b5e3252023b6d94a251160ec61120 14-Aug-2009 Philippe Saint-Pierre <stpere@gmail.com>

StringEditor : The TextView wasn't sending messages saying its content was modified by the user.
Symptoms :
* The Save menu item wasn't enabled
* the undo/redo menu item weren't neither

The fix I made was to commit the changes made by the user to the editor instance, by augmenting the InsertText and DeleteText from the TextView.
This fixes ticket #3507.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32402 a95241bf-73f2-0310-859d-f6bbb57e9c96


# f6e4cbb95290a74b33d012600438b84742b0e572 15-Oct-2007 Axel Dörfler <axeld@pinc-software.de>

* Rewrote BeBuild.h which had "a few" consequences (got rid of all those class
definitions).
* Minor cleanup here and there.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22577 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 6f850dfd449d3e2976aa5107d15c440dd807c087 26-Mar-2006 Axel Dörfler <axeld@pinc-software.de>

Build fixes for the R5/Dano target, no longer relies on the COMPILE_FOR_R5 macro.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16887 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 9e98ea36fd14c9c0e072eedb30280a653304933d 17-Dec-2004 Axel Dörfler <axeld@pinc-software.de>

The DataEditor now has a separate entry_ref for attributes - that's used
to have access to the attributes of a root directory. Internally, only
this ref is used when accessing attribute data.
Also fixed an initialization bug in case the stream couldn't be properly
opened; some values were just set too late (could lead to strange things
as well as a crash).


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10481 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 0283ecc0cd8bcfc350216b80c1d87a7096c44015 29-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

Implemented case insensitive search. It's now available in hex mode as well.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6822 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 8db249194cd850b2122f3d76f101cbcc26fd28ac 27-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

Implemented find functionality. The find panel is still missing though, it
just searches for "test".
The find itself is implemented in DataEditor::Find() which sets the editor
in read-only mode and searches for the specified data. It will update a
progress monitor, it will find data no matter if it's on a view size break,
and it is interruptible at any time.
The DataEditor change methods now respect the read-only mode, and return
B_NOT_ALLOWED in this case.
Renamed the UpdateLooper class to EditorLooper class, since it now also
runs the find action.
The ProbeView class now maintains the "Find Again" menu item; it's target
message always contains the item that last searched for.
The HeaderView will now show a "Stop" button while the search operation
is in progress; it also acts as the Find() progress monitor.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6789 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a7511f36548f2c94f7889f809e274753e4ef09c2 26-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

Implemented changing the block size - that caused several changes to
DataEditor::SetViewSize()/SetViewOffset() because they did not correctly
update some values under certain circumstances.
There is now a kMsgDataEditorParameterChange instead of just ...OffsetChange;
the message will contain information about what has changed exactly.
Added a new kDataViewPreferredSize notifier that indicates a change of
the preferred size of the DataView. The ProbeView now listens to that
instead of knowing when to update the window limits.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6772 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a4ce63bfc4ca46d872d218c2da53cb53da219704 26-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

Implemented Save() functionality. ApplyChanges() can now create the editor
version of the file from any state.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6763 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c65f61d4ad188611beaa221851599820bbdc71e9 26-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

Added a StateWatcher class that will automatically send notices for
all changed states during the lifetime of the object upon destruction.
Added some comments.
Uncommented the IsModified() method (does not yet work correctly, though).


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6760 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 707aa753f3e2e387b69ea3d01fba63013236e015 25-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

Removed DataEditor::SetToAttribute() method.
DataEditor::InitCheck() is now properly working for all types.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6747 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 66fcb84e31c9c6f645bafa46ac145fa95f44612a 24-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

Now maintains the undo/redo state watcher, and also the data update
containing the range of affected bytes.
Added missing initialization of fLastChange and fFirstChange.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6733 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 32069a88fa551430cf3a8bbbdc250a5586040f28 24-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

Made the attribute type accessible read-only.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6711 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 84a09d60e166b9a62412e4672e6645ec04beb49f 23-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

No longer takes an attribute for a file, or a device for an attribute.
Implemented attribute support.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6709 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 053bb7380a14cb55cd8dfcdf6d5ec753b0355f1e 23-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

Added a UpdateIfNeeded() method that you can call when you are not
interested in the data at all.
No longer imitates the BHandler observer model, but directly send
its update messages to the observers.
Now also stores the entry_ref of the file/device in the editor.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6704 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 602992140d69561077b9fafbdc49272fa30cdf41 18-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

Implemented proper focus handling in DataView instead of forcing focus
whenever the window got activated.
New DataView::MakeVisible() makes sure the specified position is visible
in the view, and scrolls to it if not (both, horizontally and vertically).
Implemented cursor navigation and selection extension in the DataView class.
Fixed a bug in DataView::SetSelection() that could let slip through invalid
values.
Renamed DataEditor observer notices.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6634 a95241bf-73f2-0310-859d-f6bbb57e9c96


# f7efc8f44741886f45983bfc95d629e78f27b4bb 17-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

The DataEditor class is now subclasses from BLocker instead of aggregating
it. This way, it can directly be used in the BAutolock class, and also provides
some more sophisticated locking functions.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6621 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 8b6c387e957b5acbbb8552fdf152d97451ab7da4 12-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

Fixed the wrong return type of ViewSize().
Reduced the number of state message types.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6570 a95241bf-73f2-0310-859d-f6bbb57e9c96


# f748e2d460fd3b179aecd7092fb46ec5daf450f6 11-Feb-2004 Axel Dörfler <axeld@pinc-software.de>

Extended watching mechanism (it now works more like the BHandler watching
mechanism) - it's not really used yet, though.
Fixed some variable initialization bugs and missing return values.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6566 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1df68d1dee54532fb02515cff83c9d8392adacd0 15-Jan-2004 Axel Dörfler <axeld@pinc-software.de>

Started to work on a DiskProbe replacement as a side project.
Implemented the basic editor engine that has features like undo/redo
and everything else DiskProbe could possibly need - not complete yet,
though it already has everything that would be needed for a 1:1 DiskProbe
duplicate.
The DiskProbe app is currently just a small text based test for that engine.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6096 a95241bf-73f2-0310-859d-f6bbb57e9c96