History log of /haiku/src/kits/tracker/TrackerSettings.h
Revision Date Author Comments
# 90510b4a 05-Dec-2023 John Scipione <jscipione@gmail.com>

Tracker: Remove Trash settings remnants

PoseView.cpp changes
* Create DoDelete() and DoMoveToTrash() convenience methods in BPoseView.
- Call DoMoveToTrash() in B_DELETE handler checking Shift.

Tracker: Update Delete warning dialog

This dialog pops up when you Move to Trash with Shift held down.

The Skip Trash version has been deleted since we've decided to
no longer using this settings.

Push Cancel button over to right on the "Delete files" version.

Handle default case in switches so that a weird value is returned it
will Cancel. If BAlert receives B_QUIT_REQUESTED it returns -1 for
example according to the Haiku Book so make sure to handle this case.

Add B_CLOSE_ON_ESCAPE flag and handle that case.

Change-Id: I16c532bfef585081207f1df3edc93f69dec6e529
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7199
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>


# 7f819534 05-Aug-2021 John Scipione <jscipione@gmail.com>

Tracker: Add thumbnail support

Define thumbnail attributes in Attributes.h:
Media:Thumbnail to store the thumbnail,
Media:Thumbnail:CreationTime to see if thumbs need to be regenerated.

Store 128x128 thumbnail in attribute, for icon sizes smaller than
128x128 down-scale the 128x128 thumbnail. Use B_FILTER_BITMAP_BILINEAR
to down-scale the image using the bilinear scaling algorithm which
creates nicer looking thumbnails than the default scaling algorithm.

Store thumbnails as WebP images which compress smaller than PNGs and
fit in the inode better at 128x128.

Check the file's modification time in GetFileIconFromAttr() and compare
it to the thumbnail creation time. If the file has not been modified
since the last time we generated thumbnails return the thumbnail from
the attribute, otherwise fetch a new thumbnail with GetThumbnailIcon().

Add "Generate image thumbnails" Tracker setting. Default is turned off
for now. To generate image thumbnails you must first turn this setting
on in Tracker Windows preferences.

Spawn a get_thumbnail() thread to generate thumbnails and retrieve them
later on from the window thread to fill out into the icon. This should
improve responsiveness of generating thumbnails from a folder with a
lot of images. The generator thread will write the thumbnail data to an
attribute if on writable BFS volume.

If not on writable BFS volume, the generator thread will send the data
back to the original thread through a port by calling write_port().

When the thread is finished creating the thumbnail it sends a message
back to the Tracker application thread to update the pose which
instructs the window thread to look for an thumbnail. It either finds a
thumbnail in an attribute, or picks up the thumbnail data that has been
sent through write_port() using read_port().

This works on both read-write and read-only BFS volumes but it still
depends on the presence of a BEOS:TYPE parameter to have been written
to the volume before it became read-only. Thumbnail generation does not
work on other read-only volumes for example an ISO-9660 CD, but it does
work on read-only BFS volumes for example the BeOS R5 CD.

Move BPrivate::CheckNodeIconHintPrivate() from BNodeInfo to Tracker
Model CheckNodeIconHint(). Create Model::CheckAppIconHint() and look
for a vector icon or mini and large icon in that method. Check that
the base type is directory, volume, trash, desktop, or if executable
call CheckAppIconHint().

Add 1 to temp_name to fix the following warning:
src/kits/tracker/FSUtils.cpp:2437:12: note: 'snprintf' output 3 or more
bytes (assuming 267) into a destination of size 266

Rename temp_name to tempName following our style guidelines. Use
strlcpy() and strlcat() instead of strcpy() to safely copy the string.
This fixes thumbnail generation on 64-bit Haiku.

Change-Id: I7f927a5a1f8cf65e4b1aa1e0eb55bbfae87fd969
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3163
Reviewed-by: John Scipione <jscipione@gmail.com>
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>


# 4c081057 20-Jun-2014 John Scipione <jscipione@gmail.com>

Tracker: style fixes to TrackerSettings


# 163a3948 09-Feb-2013 Humdinger <humdingerb@gmail.com>

Revert "Renamed Tracker option "Don't move files to Trash" (#9352)"

This reverts commit 45f77dcd7029914ccd99178dfb333eb68c7af9e5.


# 45f77dcd 06-Jan-2013 Humdinger <humdingerb@gmail.com>

Renamed Tracker option "Don't move files to Trash" (#9352)

Renamed that option as it is the only negatively phrased to
"Move deleted files to Trash first" and also the option below
that to "Ask before deleting for good".
Also renamed every function name etc. in that regard and also
settings string of the Tracker settings file.


# db416834 02-Jan-2013 Matt Madia <mattmadia@gmail.com>

Automatic whitespace cleanup. No functional change.


# b05aa8b5 27-Jul-2012 John Scipione <jscipione@gmail.com>

Style changes in Tracker, no functional change.

Manual whitespace cleanup
Change instances of const char * to const char*
Convert /* */ C style comments to // C++ style comments


# 545ebde0 30-Jan-2010 Michael Lotz <mmlr@mlotz.ch>

Implement type ahead filtering (this time for real and without abusing the
vertically sorted pose list). When enabled typing will filter based on the
currently visible attribute columns. Using shift-space as a delimiter
independent filtering strings can be typed, so you can filter based on multiple
attributes at once to refine results while you type. Filtering stays active
until you cancel it using the escape key. While the filtered result is displayed
all normal file operations can be used. Using the return key while filtering
auto-selects and opens the first filter result, allowing for fast traversal
through directories and directly opening the topmost result.

* Introduces fFilteredPoseList which stores the active filter result. The list
is only used when filtering is currently active, so no syncing is required
otherwise.
* Some minor adjustments to leave out invalidations where non-visible poses are
updated.
* Account for the now possible multiple lists throughout BPoseView.
* Add filter string output to the CountView and made that one a bit wider.
* Added all the settings-cruft for type ahead filtering (defaults to off).


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


# 671dd808 12-Jan-2010 Rene Gollent <anevilyak@gmail.com>

Various cleanups:
* Removed dead/obsolete Integrate Non-boot Desktops code.
* Modified PoseView to ignore the fInvisible attribute of BPoseInfo for now.
This has the net effect that the Desktop folder and /boot/var are no longer
hidden from the user. To go with this change, Tracker no longer forcibly
writes that hidden setting to those folders on access. This feature might
be useful again in the future (especially in conjunction with relocating
the Trash folder somewhere such as the disk root), but is currently somewhat
problematic because those dual-booting with BeOS will still have a Tracker
that force writes those attributes which would bring us back to square one
with respect to showing the Desktop folder when we start respecting the
attribute again. Suggestions welcome. Haiku-only users can remove the
_trk/pinfo_le attribute on those folders to remove the invisibility
in any case.
* TrackerSettings: Removed obsolete desktop integration settings. Also
modified TrackerSettings parser to skip unrecognized settings instead
of aborting the settings file parsing process entirely.

Closes ticket #2872.



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


# 02be5353 22-May-2005 Axel Dörfler <axeld@pinc-software.de>

Added libtracker.so to the repository and the build.


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


# 4c0810574e3f0f2f517e1791880ca9362f10cd53 20-Jun-2014 John Scipione <jscipione@gmail.com>

Tracker: style fixes to TrackerSettings


# 163a39483387c5db4156dfcf36e4b48156df30a6 09-Feb-2013 Humdinger <humdingerb@gmail.com>

Revert "Renamed Tracker option "Don't move files to Trash" (#9352)"

This reverts commit 45f77dcd7029914ccd99178dfb333eb68c7af9e5.


# 45f77dcd7029914ccd99178dfb333eb68c7af9e5 06-Jan-2013 Humdinger <humdingerb@gmail.com>

Renamed Tracker option "Don't move files to Trash" (#9352)

Renamed that option as it is the only negatively phrased to
"Move deleted files to Trash first" and also the option below
that to "Ask before deleting for good".
Also renamed every function name etc. in that regard and also
settings string of the Tracker settings file.


# db41683495bfde817554415d14ae6f9cc91e77eb 02-Jan-2013 Matt Madia <mattmadia@gmail.com>

Automatic whitespace cleanup. No functional change.


# b05aa8b5b16e5b4f420a35c37805c6387df98737 27-Jul-2012 John Scipione <jscipione@gmail.com>

Style changes in Tracker, no functional change.

Manual whitespace cleanup
Change instances of const char * to const char*
Convert /* */ C style comments to // C++ style comments


# 545ebde00c3d50510a5236de1c5eef25ac21d757 30-Jan-2010 Michael Lotz <mmlr@mlotz.ch>

Implement type ahead filtering (this time for real and without abusing the
vertically sorted pose list). When enabled typing will filter based on the
currently visible attribute columns. Using shift-space as a delimiter
independent filtering strings can be typed, so you can filter based on multiple
attributes at once to refine results while you type. Filtering stays active
until you cancel it using the escape key. While the filtered result is displayed
all normal file operations can be used. Using the return key while filtering
auto-selects and opens the first filter result, allowing for fast traversal
through directories and directly opening the topmost result.

* Introduces fFilteredPoseList which stores the active filter result. The list
is only used when filtering is currently active, so no syncing is required
otherwise.
* Some minor adjustments to leave out invalidations where non-visible poses are
updated.
* Account for the now possible multiple lists throughout BPoseView.
* Add filter string output to the CountView and made that one a bit wider.
* Added all the settings-cruft for type ahead filtering (defaults to off).


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


# 671dd808619ef6043eca11b09a193d877181d10f 12-Jan-2010 Rene Gollent <anevilyak@gmail.com>

Various cleanups:
* Removed dead/obsolete Integrate Non-boot Desktops code.
* Modified PoseView to ignore the fInvisible attribute of BPoseInfo for now.
This has the net effect that the Desktop folder and /boot/var are no longer
hidden from the user. To go with this change, Tracker no longer forcibly
writes that hidden setting to those folders on access. This feature might
be useful again in the future (especially in conjunction with relocating
the Trash folder somewhere such as the disk root), but is currently somewhat
problematic because those dual-booting with BeOS will still have a Tracker
that force writes those attributes which would bring us back to square one
with respect to showing the Desktop folder when we start respecting the
attribute again. Suggestions welcome. Haiku-only users can remove the
_trk/pinfo_le attribute on those folders to remove the invisibility
in any case.
* TrackerSettings: Removed obsolete desktop integration settings. Also
modified TrackerSettings parser to skip unrecognized settings instead
of aborting the settings file parsing process entirely.

Closes ticket #2872.



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


# 02be5353fd41ea40007a382e13f007eaf6b5a3a0 22-May-2005 Axel Dörfler <axeld@pinc-software.de>

Added libtracker.so to the repository and the build.


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