Commit Graph

582 Commits

Author SHA1 Message Date
Stefano Ceccherini
4db1f9f387 Use BMenu::RemoveItems() instead of iterating.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37488 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-07-13 08:21:19 +00:00
Rene Gollent
140f3bd884 WellKnownEntry used a const char * to store the name of its entry, but didn't actually copy the passed-in string, only its pointer. Since the entries were all populated via strings off the stack, this led to them being overwritten with random garbage during program execution. In the best case, this would result in well known icons such as the ladybug boot volume failing to resolve. In the worst case, this likely led to random corruption/crashes. Fixed by having them store a BString instead.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37476 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-07-12 02:06:29 +00:00
Rene Gollent
fc7c01a114 Fix typo spotted by Clang. Resolves ticket #6253.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37358 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-07-02 19:48:13 +00:00
Stephan Aßmus
2376696dd9 Provide the HVIF version of the printer spool type. These types should really
be moved into the mime database source... but anyway, thanks to Meanwhile for
the icon! Reference: Ticket #1429.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36864 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-05-19 11:17:04 +00:00
Rene Gollent
9a708202ac FSCreateTrashDirs mustn't create the directories itself. This breaks the logic in FSGetTrashDir that creates/applies attributes if needed. This most likely explains Axel's random problems with trash directories being visible, since this would cause a fresh Haiku install's /boot/trash to never be marked invisible as it should be.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36816 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-05-15 02:05:45 +00:00
Stephan Aßmus
3ddefbc1d4 Fixed warning.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36812 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-05-14 16:41:58 +00:00
Axel Dörfler
1e9e9da389 * I'm not sure why it happens, but the drag bitmap offset was BPoint(2, 1) off
(that should be good enough for the current Tracker).
* Minor cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36787 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-05-11 08:01:36 +00:00
Axel Dörfler
9c8f23673b * Never choose a target pose in UpdateDropTarget() that is part of the currently
dragged selection. This fixes the context menu popping up when you try to
  move around an icon a few pixels only.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36786 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-05-11 07:46:19 +00:00
Jérôme Duval
4dc62bba59 FavoritesMenu: don't call the RefFilter when the model's node is NULL. Fixes bug #5871.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36772 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-05-09 12:11:52 +00:00
Stephan Aßmus
da8169406f Don't open context menus right under the mouse so that the first item is
already selected and get's picked when the user releases the mouse right after
the initial click. For model context menus, like right clicking a mounted disk
on the desktop, this somehow worked without selecting the item. But opening
the context menu on an empty part of the desktop always selected the Desktop
entry which resulted in the menu immediately closing without any effect. The
perhaps unwanted side-effect of this change is that navigation menus don't
automatically open unless you move the mouse a bit. Please play with this a bit
before commiting to alpha branch. I remember having to move the mouse a bit
on R5 as well, but could be wrong about it.

The real fix would be in BMenu and BMenuBar tracking code, but the changes
which I would have in mind are too radical to do before the release. I
understand that _IsStickyMode() is supposed to handle this case, but it actually
has too little information, since each menu is tracking the mouse state itself
and doesn't know what another menu already knows. Perhaps this is what the
"start" parameter was for in the original _Track() hook, but why not simply
create an object which is passed from menu to menu and tracks everything of
relevance and maintains state?


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36762 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-05-08 22:41:55 +00:00
Rene Gollent
bdb32d10a9 Simplify the check for what volumes to show free space bars on. They are
now shown only on read/write volumes that are not CDDA.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36610 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-05-04 15:17:21 +00:00
Rene Gollent
4ab96afd71 Use openAnyways mode instead of click to open rect for tracker context
menus. May help with #3267.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36607 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-05-04 14:24:12 +00:00
Alexandre Deckner
ecdb5ec668 * Filter out B_INSERT and B_FUNCTION_KEY as they would end up in type ahead "default" case. Fixes #5609. Looking at all the not already caught keycodes, this should cover every cases.
+alphabranch


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36593 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-05-03 00:13:59 +00:00
Alexandre Deckner
08b3ae9bb2 * RemoveFromVSList was failing to actually remove some poses due to a buggy optimisation. This was causing calls on invalid poses in many places in the PoseView code (icon mode). This fixes #4322 (and duplicate #5780). This should also fix #3828. Please test.
I took the conservative approach and the penalty is really minimal if even not at all perceptible as i've measured. I decided to go this way as PoseView code is very fragile and depends on many of those "loose assertions" to be valid. This conservative approach also allows to confidently include the fix in alpha2:
+alphabranch

   Besides those "wise" reasons, the thing is that i've wasted too many hours already this week and in the past due that VSPoseList/PoseList syncing fragility. I'm not willing to fix the optimisation of a broken design that i've already experimentally rewriten two times already, and that i (or any mentally sane person) will finally ditch sooner or later :)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36592 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-05-02 23:32:54 +00:00
Rene Gollent
f7cf319589 PoseView::MoveSelectionInto() needs to check for the case that the source
window actually has a selection list to use. Certain actions can render it 
possible to empty out the selection in mid drag-and-drop, which MoveSelectionInto
wasn't taking into account, leading to a crash.

Fixes ticket #5860.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36543 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-04-29 23:57:50 +00:00
Axel Dörfler
0230fc14ea * Neither ours nor BeOS' find_directory() will return an error if the directory
does not exist yet.
* Therefore, only BDirectory::SetTo() will fail if the trash does not exist
  yet. Changed the code to actually work as expected, now.
* Fixed old and new style violations.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36524 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-04-29 07:37:06 +00:00
Rene Gollent
ca34b4221c Only write the icons if we did in fact have to freshly create the Trash directory. Should fix #5827 completely.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36522 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-04-28 20:17:30 +00:00
Rene Gollent
0872569da9 Temporarily comment out writing the vector icon since it currently appears to be broken somehow. Will look into it tonight.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36521 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-04-28 18:47:47 +00:00
Rene Gollent
63ebfa8d08 When creating Trash directories, Tracker would only set the hidden and/or icon attributes at startup for volumes mounted at that point in time. Volumes mounted later would have the directory created, but not marked hidden or otherwise attributed, which would lead to confusing situations where the root Trash dirs would appear randomly while browsing the filesystem.
Instead, Tracker now always writes those attributes when calling FSGetTrashDir(), which is reused by FSCreateTrashDirs(). Fixes ticket #5827.




git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36520 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-04-28 18:30:04 +00:00
Alexandre Deckner
ab5fb573e5 * Removed what finally looks like an old (and not needed anymore) workaround. That is, the sending of a message when dropping a pose over another one while its context menu is still showing. That was causing #4757 since poseview was receiving the dropped message two times.
I've been investigating the issue in depth, it's there since the first opentracker revision, so i even installed R5 and built/debugged opentracker to confirm it was indeed needed on R5. That would be another case of undocumented (misdocumented) workaround for an R5 bug, ie: BMenu would steal the drop message although the mouse isn't over it anymore (Stefano idea?). Heh if only i could reach the original Tracker devs :-D 

  I don't like when i don't understand a problem up to the last bit, but it should be reasonably safe for alpha2 +alphabranch


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36516 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-04-28 13:37:27 +00:00
Rene Gollent
b64b6705ad Factored out initialization of default values into an _Init() function that's now called by all constructors.
The BMessage version of the ViewState constructor was not retrieving the icon/last icon size values.

May fix #4322.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36455 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-04-24 19:35:53 +00:00
Rene Gollent
01e63caf83 When creating a new pose, the index offset at which it was inserted in list mode was never passed back. Consequently, when creating a new folder via the cmd+N shortcut (which immediately goes into edit mode), the TextWidget for editing would appear at the wrong location.
Fixes ticket #5774.

+alphabranch



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36408 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-04-22 02:02:55 +00:00
Adrien Destugues
8f2d34d9e0 Fix test_app_server again due to Coding Sprint changes
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36195 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-04-12 20:02:43 +00:00
Adrien Destugues
e9024a3be5 * Build tools : allow to run DoCatalogs with a custom regexp for special cases
* Introduce a system-wide localization catalog used for strings hidden deep in some libraries. Add special API to get it.
 * string_for_size is the first to make use of this system wide catalog. This allows to have a fully localized DriveSetup.
 * As a side effect, tracker also uses it. It now requires liblocale.so.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36175 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-04-11 23:00:25 +00:00
Stephan Aßmus
48d796576e * Moved the duplicate "string_for_size()" implementations into libshared.a.
* Adapted libtracker.so, DriveSetup and Installer to use the shared version.
 * The new version uses the correct units (KiB instead of KB and so on).
 * Use the correct units in a few other prominent places, where
   string_for_size() could not be used.

Should resolve a major part of #5378.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35935 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-03-23 16:49:49 +00:00
Stephan Aßmus
769912c87b Use the new cursors.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35891 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-03-17 12:39:24 +00:00
Rene Gollent
7c0f5738b3 Remove Tracker's special DnD handling. Instead, BTextView/BTextControl now
honors drag messages containing entry refs and resolves the path of the first
one contained. Will work on a more sophisticated solution that would allow
optionally extracting the file text instead via right click drag context menu 
when I have more time.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35731 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-03-03 00:02:02 +00:00
Rene Gollent
ddee094350 Add an extra sanity check to Tracker's automatic text clipping extraction when
drag and dropping text files: before it would blindly read the entirety of the
file's text contents regardless of size, which probably led to more than a few
nasty surprises when someone attempted to drag very large (i.e. multimegabyte)
text files. We now clamp the amount of data we read to 64KB. Though it's
debatable if this feature is at all useful, since it may potentially be better
implemented by handling entry_refs in dropped messages in BTextView directly
(assuming a compatible type). Opinions welcome.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35715 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-03-02 00:51:17 +00:00
Axel Dörfler
f24e3c9f1e * Fixed warnings and coding style violations.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35557 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-02-21 17:22:34 +00:00
Artur Wyszynski
cee04e8074 Fixed various errors/warnings reported by cppcheck:
* memory leaks
* resource leaks
* added const's to getters
* removed a few reundant conditions


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35433 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-02-08 22:50:38 +00:00
Rene Gollent
7438e94206 Fix spacing.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35430 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-02-08 00:47:11 +00:00
Rene Gollent
807bdfdf67 As pointed out by mmlr, we only need to provide the symbol, and only in the case of gcc2.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35429 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-02-08 00:46:22 +00:00
Rene Gollent
a5c2457fa8 Re-add dev_t version of FSGetDeskDir for bin compat reasons: BeIDE (unfortunately) appears to make use of some of the private FSUtils calls. Reimplemented call to use the normal FSGetDeskDir ignoring the passed in volume argument since we no longer have a desktop directory any place else. Fixes the problem reported in #5135.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35428 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-02-08 00:36:25 +00:00
Michael Lotz
029f4e9317 * Add an inline CurrentPoseList() that returns either the filtered or normal
pose list and replaced the rather ugly "fFiltering ? ..." everywhere with it.
* Automatic whitespace cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35389 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-02-02 17:56:52 +00:00
Michael Lotz
cc5b851813 No need to lock out the normal typeahead when filtering doesn't apply (i.e. in
icon mode). And a little automatic whitespace cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35388 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-02-02 17:37:53 +00:00
Michael Lotz
0086654c68 Automatic whitespace cleanup, no functional change.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35376 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-02-01 05:36:59 +00:00
Michael Lotz
b3e4ce5422 Use the multibyte aware string functions for typeahead search and filtering so
that special characters can be used as well (umlauts for example).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35375 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-02-01 05:30:08 +00:00
Michael Lotz
7acdd03f5e Replaced the sMatchString buffer used for typeahead search by a BString. No
intended functional change.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35373 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-02-01 05:02:05 +00:00
Rene Gollent
ef9c0b6a51 More cleanups:
- remove some more leftover desktop integration-related code.
	- remove special case that would hide the Desktop folder in file panels.
	- fixed BFilePanel to correctly filter out the trash from the volume root
	  and show it on the desktop like everywhere else.
	- renamed CountView::Add/RemoveFilter so they don't hide
	  BHandler::Add/RemoveFilter (gcc4 warning).



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35368 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-31 21:27:14 +00:00
Michael Lotz
83c03b5698 Missed the re-insertion when exiting early after checking the sort order for a
pose on a non-visible pose list which would cause poses to get lost from the
unfiltered list.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35354 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-31 02:28:29 +00:00
Michael Lotz
497aa62c2f * Provide a LaunchLooper that receives launch messages and executes the launch
functions provided with the given arguments.
* Make use of that looper to replace spawning a thread for each launch task.

On the one side this reduces the amount of used threads (and should fix #698)
and on the other side it makes the order in which refs are sent a bit more
predictable.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35351 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-31 00:25:10 +00:00
Michael Lotz
6a5cf0a1f2 Allow shift-return to discard the filter so you can decided whether or not the
filter shall stay in effect when opening a selection.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35347 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-30 18:17:22 +00:00
Michael Lotz
2932770972 Fix missing check that would cause non-matching poses to show up on attribute
changes (which may also happen on creation of new files).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35346 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-30 17:41:26 +00:00
Michael Lotz
ac53da69c7 When initially starting filtering we need to make sure that non-matching poses
fall out of the selection. The same is later done when removing them from the
matching subset, so moved that to a common EnsurePoseUnselected().


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35345 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-30 17:10:46 +00:00
Michael Lotz
beb2e05421 * Renamed CancelFiltering() to ClearFilter() to make it more clear what it does.
* Add UpdateAfterFilterChange() with the update part of FilterModified().
* Add StopFiltering() that clears the filter and updates.
* Make use of these functions where appropriate to fix missing scroll ranges
  after canceling a filter.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35344 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-30 16:53:53 +00:00
Michael Lotz
545ebde00c 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
2010-01-30 08:08:58 +00:00
Stephan Aßmus
16940ab877 Now that the speed is displayed right away, increase the number of slots for
calculating the average speed to get a more stable value.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35141 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-18 08:52:42 +00:00
Rene Gollent
89af054816 Employ a similar naming abstraction for the desktop as has been done for Trash to allow that name to be localized visually later (same on-disk location though).
SlowContextPopup also needed to be adjusted to account for trash's new location.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35137 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-17 21:35:42 +00:00
Stephan Aßmus
35de4b4862 Implement showing the estimated time to finish a file process. It will toggle
automatically between showing amount copied + speed and estimated finish time
+ time left. It could be implemented to toggle on mouse click, but then it would
be a hidden feature. Comments welcome.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35136 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-17 21:02:50 +00:00
Rene Gollent
b37100b2bf Missed a few instances in the previous cleanup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35134 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-17 20:07:30 +00:00
Rene Gollent
d9626569fb Model: Add accessor for Trash node property and cleanup spacing between inlines.
Rest: Use the IsTrash() accessor on Model where possible in place of the more expensive FSIsTrashDir() check.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35132 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-17 19:58:46 +00:00
Stephan Aßmus
9589965cbd Change the algorithm that calculates the average copy speed, so it begins to
display much earlier (two seconds).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35131 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-17 19:47:22 +00:00
Stephan Aßmus
4e1bbd4d0d Implemented display of current size/total size copied and current copy speed.
It will begin to play after a short time (10 seconds). Estimated finish time
is still a TODO.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35129 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-17 18:40:25 +00:00
Stephan Aßmus
406799c165 Copy and paste bugs prevented the copy progress bar to function properly.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35128 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-17 18:39:05 +00:00
Rene Gollent
0e848e2d69 Fix error spotted by Adrien: don't return Trash name for anonymous volumes.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35127 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-17 18:27:21 +00:00
Rene Gollent
6abd81fcf0 Add a special node type for the Trash analogous to the one used for the root dir. This allows the model to return an arbitrary name not directly tied to the on-disk name for the Trash directory, which a) makes it localizable in the future, and b) means it's not tied to the on-disk name, which removes the requirement that the Trash dir name be uppercase on disk.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35126 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-17 18:12:39 +00:00
Rene Gollent
782fbf00a7 Overlooked this with my previous Trash-related changes: updated NavMenu to be
behaviorally in sync - it now hides the root volume Trash dir like PoseView,
and adds the Trash entry as needed when navigating down the Desktop.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35125 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-17 17:35:06 +00:00
Rene Gollent
aa61ee48ef Cleaned up legacy icon mappings and add some missing resource definitions to
TrackerIcons.h. Also removed the setup for the folder icon mimetype in 
TrackerInitialState, as it was using a non-existent resource ID to do so with.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35118 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-17 16:35:40 +00:00
Stephan Aßmus
3cc5c3ffb1 Further cleanup of TrackerLoopControl. gStatusWindow is now nowhere used anymore
except inside TrackerLoopControl. The only expected change of behavior is when
trying to copy something onto a read-only volume. AFAICS, it would previously
prompt an alert and not already show the status window. Now it will show the
status window and prompt an alert, like in all the other situations when the
operation would be stopped before it even started by an alert. I was able to
remove quite a few code duplications along the way. CopyLoopControl can be
instantiated by itself and provides default implementations which could in turn
be removed from TrackerLoopControl.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35115 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-17 13:32:06 +00:00
Stephan Aßmus
8aad948744 * 80 chars/line limit cleanup
* Fixed one more occurance of "dos" filesystem check.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35113 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-17 12:16:22 +00:00
Stephan Aßmus
0bf7f1f8cd When an error occurs to incrase the node monitor limit, reset the current
value and don't keep it at the value we wanted it increased to.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35112 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-17 12:15:50 +00:00
Rene Gollent
7ca5e8873b * PoseView: Re-enabled respecting the invisible pose attribute.
* FSUtils: Mark the root-level Trash directories as invisible. For the time being, 
  this renders the Trash only visible on the Desktop once more, pending 
  further consensus on how to handle it in the future. Note however that 
  this also means that Desktop and/or var directories that still have the 
  old _trk/pinfo_le attribute from prior to the previous visibility changes
  will also be marked invisible again, and those people dual-booting older 
  BeOS will also still see this issue as the Tracker on those will still
  force-write the invisible attribute onto those directories on every volume.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35094 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-15 23:44:39 +00:00
Rene Gollent
a65ec15376 Fix style violations (thanks Axel!).
Update filesystem name in find_directory as our fat filesystem is not named "dos".



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35093 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-15 23:31:45 +00:00
Rene Gollent
01dffd8edd More Tracker refactoring:
* relocated Trash dirs to volume roots by modifying find_directory() to report the trash location as volume/Trash.
 * FSUtils no longer creates /home/Desktop on every volume.
 * TrashWatcher now keeps icons in sync on all volumes.
 * Simplified FSGetDeskDir since it no longer has to worry about getting the desk directory on any volume other than the root.
 * Relocated trash context menu logic to BContainerWindow so it can also be used at the volume roots.
 * DesktopPoseView now creates a virtual Trash pose representing the trash contents as before.
 * Corrected typo: Model::WriteAttrKillForegin() -> Model::WriteAttrKillForeign().

Closes ticket #5245.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35085 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-15 05:12:45 +00:00
Rene Gollent
7b6edf5209 Simplified FSIsDeskDir() as suggested by Axel. Thanks!
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35082 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-14 23:40:13 +00:00
Rene Gollent
167898484d FSIsDeskDir should only consider a path to be the desktop if it lives on the boot volume. Fixes non-boot Desktop dirs still showing the volumes and such in windows and nav menus.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35065 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-13 23:50:53 +00:00
Stephan Aßmus
9869082c8d * First attempt at cleaning up the CopyLoopControl mess. Instantiate one
TrackerCopyLoopControl and pass it on when needed. Avoid access to
   gStatusWindow directly. Later on, I will try to make it possible to drop more
   files/folders onto an ongoing copy process to append it to the job, i.e. copy
   those files to the same target folder.
 * For each updating the status, entry_refs were copied instead of passed by
   reference, which was a bit unnecessary overhead.

 * Some coding style cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35055 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-13 17:20:01 +00:00
Michael Lotz
c126f2f2c4 anevilyak:
* Fix missing parenthesis in r35040 that caused node monitoring not to work.
* Minor automatic whitespace cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35053 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-13 15:52:21 +00:00
Stephan Aßmus
2865e5a048 Patch by Humdinger:
Changed strings to sentence case in the rest of the Tracker code.
Remaining part of case-tracker.diff from #5169.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35048 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-13 12:06:51 +00:00
Stephan Aßmus
82d8aaf85a Patch by Humdinger:
Changed strings to sentence case. The changes in StatusWindow and
FSUtils are missing because I have some unfinished work in progress
in those files. Will commit them separately. This is case-tracker.diff
from #5169.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35047 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-13 12:03:25 +00:00
Rene Gollent
671dd80861 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
2010-01-13 00:41:43 +00:00
Axel Dörfler
32ac103336 * The Desktop window is no longer zoomable. This fixes ticket #5173.
* Removed no longer used headers (private BeOS device API).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34890 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-01-04 16:09:15 +00:00
Rene Gollent
5b41cd61e6 Clear the navigation menu before populating it. Fixes ticket #5079.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34497 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-12-05 00:06:32 +00:00
Axel Dörfler
862508e775 * Turned on widget outline by default.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34443 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-12-02 11:49:06 +00:00
Axel Dörfler
a8af8078a4 * Cleanup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34442 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-12-02 11:42:49 +00:00
Axel Dörfler
dbba3d21f1 * Fixed wrong preprocessor statement, thanks Jeroen!
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34298 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-11-26 21:00:48 +00:00
Axel Dörfler
0d70a99f23 * Patch by Matt to replace the leaf disk overlay with a bug for non-release
versions. This closes ticket #5036.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34296 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-11-26 18:54:30 +00:00
Rene Gollent
0b0e9179c3 Pass the favorites menu a reference to the file panel's ref filter. This is necessary since favorites are no longer constrained to only being folders, and as such they need to likewise be constrained to only display supported types. Fixes another part of #4916.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34190 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-11-22 23:43:59 +00:00
Stephan Aßmus
d2b45aa3de Avoid an invalid GCC warning by using a union.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34159 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-11-20 16:37:47 +00:00
Axel Dörfler
1221df2dd8 * Improved floating point display.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34131 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-11-19 11:53:38 +00:00
Stephan Aßmus
2ecfe97e37 * Some cleanup for 80 chars/line limit
* The target volume block size is passed to the CalcItemsAndSize() function
  to get a more accurate picture of whether items will fit. Before, it would
  assume hard coded 1024 bytes block size.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34107 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-11-18 10:21:25 +00:00
Stephan Aßmus
1e179f36e2 Seems like I have forgot to commit deleting the AutoMounter code from Tracker
back then?


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34105 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-11-18 08:55:27 +00:00
Stephan Aßmus
78248acdcc The usage of BStatusWindow::HasStatus() was really bogus. First of all
HasStatus() and UpdateStatus() were not run in the same lock, so the job
view could be gone anyway. And secondly, both methods iterate over all status
items to find the one with the correct thread. Doh, if we don't have enough
work to do, lets make some! Of course this was not critical in any case...


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34104 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-11-18 08:54:44 +00:00
Stephan Aßmus
9d6405b724 Code cleanup, no functional change except for changing BWindow::Run() into
a BWindow::Hide()-BWindow::Show() combo.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34095 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-11-17 16:10:18 +00:00
Rene Gollent
f4dc59983b Partially implement ticket #4916:
- Rename "Configure Favorites..." to "Edit Favorites...".
	- Remove the old-style Configure Favorites dialog in favor of simply
	  opening the favorites folder (~/config/settings/Tracker/go) in a
	  Tracker window for the user to manipulate.
	- Rename the "Favorite Folders" section to simply "Favorites" as files
 	  are also allowed (i.e. to easily open a template document).
 	- Removed completely arbitrary (and silent) 20 item limit to favorites
 	  list.
 	- Automatic whitespace cleanup
Still to do: Grab the ref filter from the file panel (if any) and run the
favorites through it as well, since we want to filter out any non-folder
favorites that the app is incapable of handling. Also, the setting for
the favorites menu to show recent documents needs a new home, as it was
previously in the no longer existing Configure Favorites window. Suggestions
welcome, as I'm not currently seeing a spot in the Tracker prefs that would
make good sense.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34071 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-11-16 01:07:40 +00:00
Axel Dörfler
a63c61839e * The InfoWindow's name text view is now using DisallowFilenameKeys() as well.
* DisallowFilenameKeys() no longer forbids the ':', as there is no reason to do
  so.
* Automatic whitespace cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33894 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-11-05 12:37:43 +00:00
Stefano Ceccherini
315c212bfd Two lines between functions
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33844 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-10-30 12:08:15 +00:00
Stefano Ceccherini
d5ca839e4f Fix spelling error.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33843 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-10-30 12:06:34 +00:00
Rene Gollent
d3b113282a Move CheckDevicesEqual into FSUtils so it can be used in more places.
Rework ContainerWindow's B_REFS_RECEIVED to use CheckDevicesEqual to decide move vs copy as is done elsewhere.

Fixes ticket #4850.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33803 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-10-28 03:04:42 +00:00
Alexandre Deckner
e2ee5e5706 * My previous fix to #4130 wasn't correct since it could miss some moved or
renamed files. After more investigation i found out that the problem was
  caused by a non usual use of the zombie list in r31307. In the conditions
  to reproduce #4130 it would call AttrChanged() or StatChanged() on zombie
  poses which by convention should always be invalid models, ie: null node.
  The logic would potentially create other problems too as it wasn't only
  adding refFiltered models to the zombies.
  I reverted part of r31307, clarified the logic and updated the comments.
  I'd prefer another implementation for this as reusing the zombie list
  here is only calling for future mysterious problems. #4131, #4271, #4610
  and #4831 are still closed, but i'm reopening #1717 which is more of an
  enhancement btw.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33769 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-10-26 10:21:33 +00:00
Alexandre Deckner
c3ce629473 * When a file was created, then deleted shortly after, on a PoseView that is
busy processing other things, the file could be gone by the time we processed
  the fs notification message of the entry creation. This case wasn't handled
  properly and would cause #4130 and most certainly duplicate #4831, #4610 and
  also possibly #4271.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33744 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-10-23 08:07:56 +00:00
Michael Lotz
35e7c9642f Fix dirent handling. The d_reclen field contains the size of the whole record,
so it includes sizeof(dirent).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33689 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-10-20 22:52:35 +00:00
Stephan Aßmus
c1b274fd67 * Removed auto mounter code from Tracker.
* Tracker forwards auto mounter related messages to the mount_server.
* Rewrote AutoMounterSettings to not know AutoMounter and use
  the layout-management.
* Moved the "Eject When Unmounting" setting into the Mount Settings.
* Launch the mount_server during boot, but delay the script until all
  previously mounted volumes have been mounted. This solves some annoying
  timing bugs during boot. For example when you have desktop backgrounds
  on other volumes and some servers don't deal well with the situation
  of links to add-ons on other volumes becoming valid with a delay...
* src/kits/tracker/Commands.h includes the private headers/private/
  mount/MountServer.h header, which made adjustments to the DiskUsage
  Jamfile necessary.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33555 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-10-12 14:52:17 +00:00
Stephan Aßmus
994b23564f Cleanup
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33487 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-10-07 19:32:21 +00:00
Stephan Aßmus
df78ef39ab Removed BeOS version of the code.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33466 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-10-06 13:51:49 +00:00
Ryan Leavengood
0eab14cd22 Apply patch from Caitlin Shaw, aka rogueeve, to fix Tracker's replace behavior
for the case of 1 file.

Fixes #4717.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33427 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-10-04 20:52:04 +00:00
Jonas Sundström
941098a211 Standardizing on BWindow::CenterOnScreen()
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33378 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-10-01 00:03:00 +00:00
Ryan Leavengood
7c870e9af5 These are the remaining changes to properly implement the new default of volume
space bars being on. Thanks for the tips Axel.

+alphabranch


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32934 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-09-04 21:02:56 +00:00
Ryan Leavengood
9e59c0f7b9 Fix #4407 by making the volume space bars on by default.
+alphabranch


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32925 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-09-03 21:31:12 +00:00
Joachim Seemer
76e853e21f Renamed menu 'Attributes|Copy/Paste Attributes' to 'Attributes|Copy/Paste Layout'. Fixes #2835.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32908 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-09-02 16:08:06 +00:00
Alexandre Deckner
ea1a27d61a * Reworked my fix for #3617. We now check again for a double click if the pose
was not freshly selected.
+alphabranch


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32660 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-24 19:15:12 +00:00
Alexandre Deckner
725ad924ff * When checking a draw/updateRect intersection, an offset was added too early
making the check fail when Pose::Draw was called with a non zero offset.
 Fixes #4289
* Fixed an x/y typo (that had no really visible effect, the fade effect might
 need some more indepth review)
* Removed dead code, and replaced an inlined intersection check with
 BRect::Intersect.  



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32538 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-20 10:59:53 +00:00
Alexandre Deckner
f2b42dbb1b * Favorites in filepanels are always folders, the type of favorites here
doesn't depend on the 'node flavor' of the parent filepanel.
 Fixes #3624
* Minor style fix


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32530 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-20 02:19:08 +00:00
Alexandre Deckner
50f1b82d5b * Rewrote rename-click detection to be more usable. The code is much smaller
and is based on the pose selection time, not on click time. It is more 
 robust and since the selection might have been by click, keyboard or
 selection rect, it makes the behavior very pleasant (in my opinion) for
 multiselections. Try and tell me!
* Disabled the modifiers (first click editing). Too many of them, and
 conflicting with other usages, i'd like your opinions/preferences.
* Removed old, hackish and now unused DelayedEdit/SetDelayedEdit stuff.

Fixes #3617



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32529 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-20 01:19:41 +00:00
Alexandre Deckner
105f1c632e * Added a TODO about droping icons under replicants or deskbar since i
couldn't find a quick solution that wouldn't need the layouting rewrite
 (currently in redesign phase in my branch)
* In the mean time i've added desktop element avoidance in Cleanup so one
 can easily recover hidden icons without advanced shortcuts. Before that, it
 would need a CleanupAll aka shift-alt-k (which would relayout everything btw).

 Doesn't fix #4241 but at least provides a way to see your icons again easily.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32523 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-19 15:29:59 +00:00
Axel Dörfler
2c69b5b6c0 * Made the libbe_test environment basically working under Haiku - to actually
make it work, one would need to use versioning for all libbe symbols. This is
  worth an 8k price per file that links against libbe.so, so I didn't want to
  commit this as is. An alternative to this solution would be to write a
  separate application that is responsible for the app_server's window. Comments
  welcome.
* Removed BeOS compatbility of the libbe_test stuff.
* Renamed the libbe_test targets from *haiku* to *test*, ie. libbe_haiku.so is
  now called libbe_test.so, haiku_registrar is now test_registrar, etc.
* This also removes BeOS compatibility from tracker/FSUtils.cpp (all BeOS
  compatibility should be removed, but I don't want to make Alexandre more work
  in his branch, and it's not urgent at all).
* Replaced the former "run" scripts for the test environment with a single
  run script (see updated NOTES file).
* Removed the libbe_test target from some applications - this was only to help
  developing them under BeOS, and is thus no longer necessary.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32521 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-19 14:17:13 +00:00
Alexandre Deckner
bdee02b5b0 * Move cursors to Cursors.h
* Use the new copy cursor


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32520 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-19 14:16:45 +00:00
Alexandre Deckner
c5b7a0fe6a * Give a chance to volume/disks icons to save their position when changing the
"Show Disks/Volumes Icon" preference. Fixes #1559
* Automatic white space cleanup


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32513 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-19 13:19:31 +00:00
Alexandre Deckner
3074019e96 * Remove wrong check that was preventing to properly place the first pose. Fixes #4055
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32512 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-19 12:51:50 +00:00
Axel Dörfler
39fff75391 * Fixed broken sort order of all attributes.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32498 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-18 16:43:56 +00:00
Philippe Saint-Pierre
a5dc8f8639 Reverting r30894 as it seems it is what was causing the slowness reported in ticket #4247.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32441 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-16 16:44:31 +00:00
Philippe Saint-Pierre
14347545f3 Now it also considers the MimeType of symlinks targets when proposing add-ons in tracker.
This fixes ticket #2775.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32246 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-11 11:53:12 +00:00
Rene Gollent
a9218c9c2e Oops, check was reversed.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32211 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-08 19:39:33 +00:00
Rene Gollent
d726fd50a2 When picking file destinations via the slow context popup, also do the copy vs move check based on device. Fixes ticket 4202.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32210 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-08 19:36:27 +00:00
Rene Gollent
2d6de22fb5 An Open With window has no target model. PoseView's drop target handling code didn't take this into account, causing a crash. Fixes ticket #4200.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32209 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-08-08 18:08:07 +00:00
Axel Dörfler
249efd04b3 * Fixed basic layout issues, and therefore bug #4138. This panel needs a serious
usability redesign, though, so I didn't bother letting it use the layout
  engine for now.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32022 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-07-31 14:30:15 +00:00
Rene Gollent
c9d9b2da7e Remove old BeOS-era hack to prevent NavMenus from containing > 500 items. This fixes missing items when right click browsing large directories.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31858 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-07-28 20:31:49 +00:00
Axel Dörfler
7e1f710f27 * Removed the superfluous Ctrl-Alt-Up shortcut from Tracker that clashed with
the new workspace navigation.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31829 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-07-27 20:58:11 +00:00
Axel Dörfler
d219b1fcfc * Let AddMimeMenu() check if the MIME type is valid, otherwise BMimeType::Type()
could return NULL. This fixes the crashing part of #4037.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31777 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-07-26 16:46:05 +00:00
Michael Lotz
63d557f06f Fixing random GCC4 warnings. Mostly missing consts, some parentheses, some braces... Should all be harmless and not change anything.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31600 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-07-16 02:42:03 +00:00
Stephan Aßmus
5422febd0b Fixed a few coding style violations and GCC4 warnings.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31555 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-07-14 11:26:15 +00:00
Rene Gollent
a41067fcb4 When initializing a file panel, check if the view is being targetted at the desktop. If so we need to flag appropriately as we need a different iterator which will also return the volume poses. Fixes ticket #4073.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31472 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-07-08 23:22:38 +00:00
Alexandre Deckner
f207162e07 * In single window navigation mode, when navigating into a directory which had no viewstate yet (new folder) or if
fViewState didn't change, fTitleView wouldn't be reset and updated to the new column set. (unfortunately the column
 state is managed separately from the rest of the view state). That would cause crashes for example when switching
 to a directory with fewer columns and triggering a redraw of a column that shouldn't be there anymore. 
 Fixes #3710.

* TitleView::Reset didn't invalidate the view and would leave the old columns there until a redraw was
 triggered externally.

* Minor cleanup


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31378 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-07-03 00:11:19 +00:00
Stephan Aßmus
f3797c5ae5 Patch by Jeroen Oortwijn: Improve the tab-key focus-cycle ordering of the
Tracker Settings window. Thanks a lot! Fixes ticket #4051.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31339 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-06-30 16:34:13 +00:00
Rene Gollent
254d2b2d1a Fix a number of problems in PoseView:
1) If a node was filtered out by the ref filter, PoseView effectively wiped out all evidence that it ever knew the node existed and stopped listening for changes on it. Consequently, it would never notice if an attribute change such as updating the file's type made the file now eligible to be viewed. Now we keep watching the node and keep it on the zombie list until such time as it passes the filter (if ever).
2) Refresh() cleared the pose list, but not the inserted nodes list. Consequently, any nodes that were already visible before calling Refresh() would not be readded.

This fixes various problems seen in the file panels in WonderBrush (and probably others), such as the file panel initially coming up empty sometimes, and also it not noticing new screenshots,

This closes ticket #1717.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31307 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-06-29 00:06:00 +00:00
Rene Gollent
2688837424 Fix assertion when using Tracker in debug mode. This closes ticket #1636.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31286 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-06-28 02:27:59 +00:00
Ingo Weinhold
6668455281 * Use public functionality instead of private BeOS syscalls.
* Automatic whitespace cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31039 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-06-14 10:57:09 +00:00
Philippe Saint-Pierre
de81e90c0b Replaces NodeMonitor by PathMonitor in the InfoWindow to update the calculated size of the directory when a change happen.
This implement the suggestion in ticket #2868.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30894 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-05-28 14:02:41 +00:00
Ingo Weinhold
bcfe344c53 * Made our struct stat POSIX compliant again -- the time_t fields have been
replaced by timespec fields. Via macros the structure is still source
  compatible with the old one.
* Introduced header <compat/sys/stat.h> that defines the old stat structure
  (as stat_beos) and conversion functions
* Introduced versions for [l,f]stat().
* Added symbol versions for BDirectory::GetStatFor() for sake of binary
  compatibility.
* BStatable::GetStat(): Renamed the old method, changed its parameter to
  stat_beos*, and and made it private. Added a new version (using up a
  reserved vtable slot). It remains source and binary compatible.
* BRefFilter::Filter(): Changed the struct stat* parameter to struct stat_beos*
  for sake of binary compatibility. This breaks source compatibility, though,
  which we can't help, since the class doesn't have reserved vtable slots.
* Fixed several issues with the stat structure change, mostly adjusted uses of
  BRefFilter.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30830 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-05-22 15:15:16 +00:00
Stephan Aßmus
0c7085458e Make the partition ID check more flexible, if partitions just pop up out of
nowhere, we still want to be able to automount them, even though the
notification is not for a device.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30720 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-05-12 18:35:31 +00:00
Stephan Aßmus
be5788f81c Fixed a number of remaining problems with the AutoMounter:
* During boot, the mount mode was ignored for any removable volumes, they
  simply got mounted always.
* When automounting later, all partitions on all removable devices would
  be mounted, not only the ones on the newly inserted device.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30719 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-05-12 18:32:11 +00:00
Stephan Aßmus
3908951b11 * When inserting USB sticks, the read-only mount suggestion was completely
bypassed, same for invoking "Mount All". Now, the "initial scan" parameter
  is used to decide if the user should be alarmed. Basically, it means you
  get to decide for every mounted volume if you want it rather read-only.
In the old code:
- If you wanted a stick mounted read-only, you had to go to "Tracker Settings"
  and disabled auto-ejecting, unmount the stick, then re-mount to get it to
  ask you for read-only mounting.
- But then, it would remember this setting, so when you unplugged the stick
  and then replugged it, it would mount it read-only again. This may be nice
  for later, but for now, I want to decide if I am willing to take the risk
  each time.
* The new code also has the implication that when you plug a drive with more
  than one partition, you are being asked for each one. I extended the alert
  to also mention the partition name.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30716 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-05-12 18:03:36 +00:00
Jérôme Duval
7a282f3b28 * combine MovePenTo() with DrawString()
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30530 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-05-01 08:39:02 +00:00
Philippe Saint-Pierre
838eca4665 Allows "Icon Label Outline" to be disabled when no background bitmaps are chosen.
It complements r29190 and fixes ticket #2395.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30495 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-29 23:43:23 +00:00
Bruno G. Albuquerque
107d2b333b Only try to add the preferred app if it can be found, otherwise the Open With
menu would be completelly empty.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30430 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-26 15:52:01 +00:00
Stefano Ceccherini
33ce19159d if opening a document failed because the system is shutting down, don't ask the user if he wants to open the document with another application, since that would fail as well.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30358 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-24 05:11:56 +00:00
Stephan Aßmus
8baeb63aa2 Probably not good to invalidate the layout in the destructor...
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30350 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-23 18:31:22 +00:00
Stephan Aßmus
5d2a1fb46e More style cleanup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30349 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-23 18:29:58 +00:00
Stephan Aßmus
3e3d7acb90 In some ways, this is unrelated, but I had to combine this anyhow:
* Extend the PaneSwitch BControl from Tracker, so it can draw on/off labels.
  This has the added benefit that you can click the label to expand/collapse,
  like for example in the Get Info window (Permissions).
* I also added font-sensitivity features to PaneSwitch, and it can be used
  in layouted windows (untested).
* This made the "DrawButton" in the Installer superfluous.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30348 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-23 18:25:37 +00:00
Stephan Aßmus
5e71c7b1e5 Patch by Obaro Ogbo (nastee) with small changes by myself:
* Added "Close All in Workspace" menu item in the Window menu. The shortcut
  is 'Q', which is usually the Quit shortcut. Since Tracker prevents quitting
  via this shortcut, overriding it like this is ok, this was also discussed
  in the ticket #2833. I've tested that the existing functionality is not
  disturbed (ie Quit in the Settings panel still works, as does quitting
  Tracker via "hey Tracker quit"). I did not add the "Close All" menu item,
  since that feature is already available via DeskBar and when pressing the
  shift key before opening the Window menu.
* I did change the additional short cut. As with "Clean Up" versus "Cleanup Up
  All", it's now consistently the shift key, which you have to press.

Note to Obaro: The only other change was that one can set the target of the
menu item to be "be_app", that way one avoids dispatching the message in the
window. Thanks a lot for your work, Obaro!


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30205 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-16 19:32:11 +00:00
Rene Gollent
979786f1e6 Don't show the total number of items if 0 (as will happen in the case of move operations since we skip the pre-flight count for those). Fixes ticket #3722.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30140 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-12 22:33:21 +00:00
Ingo Weinhold
4fba3522e0 * Removed src/kits/tracker/OpenHashTable.h. The shared version in
headers/private/shared is newer, though with small interface changes.
* Removed the unnecessary Debug.h include in
  headers/private/shared/ObjectList.h.
* Adjusted sources using these headers, mostly by adding missing includes.
* Lots of automatic whitespace cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30123 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-11 21:24:32 +00:00
Stephan Aßmus
4024eadfda My previous fixes had an oversight and the very last fix introduced new drawing
problems. Basically, forceDraw was set to false which then prevented any new
items to be drawn when there was no scrolling necessary. Now we use a local
variable "needToDraw" that starts with "true" on each iteration. I don't really
know why forceDraw is even passed to the function in the first place. Maybe
it should be called "disabledDrawing" with reversed meaning and should be used
for windows that open on another workspace....


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30102 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-10 08:58:13 +00:00
Stephan Aßmus
039878c152 * Set forceDraw to false when we have already drawn the pose, not when
there is only some pending scrolling.
* Fixed my previous ScrollTo() change to actually scroll in the two directions
  in two steps...


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30078 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-09 19:24:45 +00:00
Stephan Aßmus
72cd1c7726 Fixed some weird fallback code, I don't think it's used and added a TODO
for whoever stumbles there next...


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30067 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-09 14:05:31 +00:00
Stephan Aßmus
080385d599 Fixed logic to detect and warn about changes in the system folder. Merged
the "system" folder and "system folder or it's contents" case.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30057 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-09 09:30:33 +00:00
Stephan Aßmus
000f19e226 Small coding style cleanup.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30056 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-09 09:29:33 +00:00
Stephan Aßmus
61d107c8a7 Fix hardcoded paths for this *test* component.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30055 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-09 09:29:07 +00:00
Stephan Aßmus
6a71afb0d1 Sorry for mixing some cleanups into this patch...
* When changing icon sizes, invalidate before scrolling. This causes silent
  scrolling in app_server and avoids a visual jerk. Everything needs to be
  re-drawn at the new icon size anyways.
* Removed the fUpdateRegion member from BPoseView. It was supposed to make
  drawing quicker, but it only made it slower. Checking for intersection with
  the update rect passed to Draw() should be much more straight forward and
  does not involve app_server communication...
* Refactored some misnamed methods, ScrollIntoView() would always draw and
  only sometimes scroll - I couldn't agree with that.
* There is a very confusing mix of "fullDraw" and "minimalRect" booleans which
  seem to be used with wrong semantics. The minimalRect flag passed to BPose::
  CalcRect() means to get the pose rect for the icon and the first column only,
  not all columns. Contrary to that, some pose rect calculation happens with
  minimalRect == fullDraw... I tried to fix some of that.
* The visible changes of this patch are when adding poses. The
  SynchronousUpate() wasn't working so well, I made it work reliably by invoking
  Invalidate() and Window()->UpdateIfNeeded(), which also takes care of any
  drawing that the app_server has to do for the background. And it's flicker
  free in double buffered mode...
  -> This fixes poses being drawn multiple times and the text getting darker.
* And there was another bug when adding poses. The extent (bottom of last item
  in list view for example) can be just above the current view bounds. When the
  next item is added above the view bounds, then the extent scrolls into view,
  but there is nothing to be scrolled in this case. srcRect is still invalid
  and so is dstRect. But destRect should be valid in this case.
  -> This fixes some poses being cut off at the bottom when opening Tracker
  windows.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30033 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-08 15:28:53 +00:00
Axel Dörfler
1f904d1e03 * If you do something, please try to do it right, or at least test it.
* The alert escape check was broken in several ways. First of all, the buttons
  can be NULL which suddenly crashed apps. Second of all, the check didn't even
  work as it was reversed.
* Also, I disabled the code for now, as I really don't think string comparison
  heuristics are the way to solve this.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30018 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-08 08:23:07 +00:00
Stephan Aßmus
7dc5caf242 When changing icon size, pose locations need saving. That's not so nice, but
pose locations are always in view coordinates from the perspective of BPoseView,
even if the unscaled location wouldn't change from the perspective of BPose.
This could be removed when storing and restoring unscaled location. I was just
not sure were all this happens.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30010 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-07 21:34:27 +00:00
Stephan Aßmus
96da4b41b0 * Fix the completely broken desktop icon size changing which I introduced
yesterday. It needs to auto-place icons which go out of view or underneath
  the deskbar or a replicant. Also it obviously cannot scroll to keep the
  view "centered" as normal Tracker windows.
* Fix/improve the desktop context menu with regards to icon size options. It
  also displays the shortcuts, which now work on the desktop too.
* When doing an icon cleanup on the desktop, not only the deskbar is avoided,
  but also replicant views.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30009 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-07 21:09:10 +00:00
Rene Gollent
e419aeed10 If drag and drop with the context menu is used (right click drag / control + drag), treat "Copy Here" as a request to duplicate the item if the destination is the same folder.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29988 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-07 03:31:33 +00:00
Stephan Aßmus
7cdbeb0e13 * Changing the icon size will now work more like simply scaling/zooming the
view. BPose converts the scale in SetLocation() and Location(), which does
  _not_ affect performance for list mode, BTW. So that should be fine.
* The center of the pose view is now locked when changing the icon size.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29974 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-06 19:46:01 +00:00
Stephan Aßmus
e70b6d957a * Cleanup in the icon mode stuff. kScaleIconMode is gone. There is simply
kIconMode and it can have different sizes.
* The "Icon Mode" super menu item is marked, when in icon mode, as well as
  the size item in it's sub menu.
* When switching from mini icon mode or list mode back into icon mode, the
  previous icon size is now restored. This also works when the folder has
  been closed meanwhile. (The on-disk format for view state has changed, so
  your folders will open with default values.)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29971 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-06 18:18:12 +00:00
Stephan Aßmus
f5bdd55475 Patch by Maxime Simon with small changes by myself: Change the icon size
menu as discussed in ticket #2431. There are only three main shortcuts for
icon, mini icon and list mode. Additional short cuts have been added to
increase and decrease the icon size. I've moved the shortcut from the 32
icon size to the menu item for the icon size menu itself. Unfortunately,
icon placement does not scale with the size (as before) and switching to
icon mode from one of the other modes does not restore the previous icon
size. Looking into it.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29967 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-06 13:50:24 +00:00
Jonas Sundström
019f90e634 Setting the escape key as shortcut for the Cancel options of Tracker's dialogs.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29958 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-05 23:47:58 +00:00
Rene Gollent
0f617d4476 Fix several cases of forgetting to include libstdc++ in the libs. This allows a successful build of Haiku on gcc4 Haiku, though it's presently unclear to me why this didn't prevent linking on any other platform (gcc2 haiku, and gcc2/4 cross compilers from FBSD had no issues here).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29957 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-05 22:33:53 +00:00
Alexandre Deckner
561b5d977b * Implements enhancement #2829, ie: change the modifier key (now shift) to force identify on
already identified files and change the menu item label accordingly so that the 'feature' is 
not hidden anymore.
 The identification mechanism will probably be automated in the future, forcing 
identification would then become the only use of this menu item.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29940 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-05 15:29:56 +00:00
Stephan Aßmus
4d16240245 * Should fix the default desktop background (Haiku logo) since the move of the
artwork folder.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29922 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-05 08:41:48 +00:00
Stephan Aßmus
86e64a7355 Patch by Maxime Simon: Add short cuts ot the icon modes. Thanks a lot! Fixes
ticket #2431.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29905 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-04 17:26:52 +00:00
Axel Dörfler
317bd7dda3 * Changed directory structure as suggested on the mailing list.
* Made the TimeZoneView less error prone, and also actually use Haiku code (the
  previous check didn't work since it used #if, not #ifdef).
* Also took the liberty to rename our boot loader to haiku_loader, since I had
  to update the nasm binary anyway. Updated the assembly sources to nasm 2.0.
* I haven't found where the synth location in the MIDI code is specified,
  though.
* Also, NetBootArchive, and FloppyBootImage haven't been updated yet. Will do
  so next.
* Some optional packages still put their license to beos/etc/licenses. I didn't
  update them yet, as we'll probably do so anyway at some point. Also, I think
  we might want to introduce a common/data/licenses instead for those.
* If you encounter any problems, please tell!


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29876 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-03 09:02:44 +00:00
Stephan Aßmus
7ce973c676 Patch by plasm with some modifications by myself: Implement natural sorting
in Tracker. Strings are compared in chunks where the type of each chunk can be
numer or string. Thanks a lot!


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29845 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-04-01 09:28:32 +00:00
Stephan Aßmus
8ad62dec5a Patch by Obaro Ogbo: Provide a PreferredWidth() implementation for the
Relation attribute column in the Open With panel. So double clicking will
size it properly. Fixes ticket #3035. Thanks a lot!


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29779 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-29 14:23:59 +00:00
Stephan Aßmus
86fb66a8dd Fixed a mixup of the flags and resize mode arguments. In my previous commit,
I wrongly assumed that viewMode == view flags.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29778 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-29 14:22:38 +00:00
Stephan Aßmus
dec2485ca0 Patch by jonas.kirilla: Allow the Tracker settings window to be quit by
Command-Q. Thanks a lot!


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29772 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-29 08:36:55 +00:00
Stephan Aßmus
0834dd807f * Use B_DRAW_ON_CHILDREN for the Desktop pose view.
* Draw the selection rect in DrawAfterChildren().
* Call DrawAfterChildren() manually in Draw(), if B_DRAW_ON_CHILDREN is not set.

This change allows replicants, in case they want to be aware of being embedded
in the desktop, to use alpha blending to draw on top of the desktop pose view.
For replicants which do not care, this patch changes nothing. When views
with B_DRAW_ON_CHILDREN invalidate themselves, they will automatically trigger
an update of children that sit on top the invalidated area, at least with our
app_server. So this change works just like one would expect, ie like
compositing views. Of course it should have flickering when app_server does not
run in double buffered mode.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29759 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-28 19:30:39 +00:00
Stephan Aßmus
af20d1a13e Small cleanups.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29729 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-26 14:07:33 +00:00
Stephan Aßmus
ce65700663 Beautified the Tracker job status window:
* Centered icon in available space.
* Improved button layout.
* Pause button remains pressed when paused.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29668 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-23 15:03:41 +00:00
Stephan Aßmus
cafee0b7f5 Improved/fixed the look of file panels. If I feel motivated enough, I may
also fix the font-sensitivity issues.
* The CountView can now draw part of the PoseView focus indication. Though I
  am not convinced anymore that I am approaching this the right way. Maybe
  scroll views should simply leave room for drawing a frame between child
  and scroll bars...
* ContainerWindow::BackgroundView uses the new BControlLook method to draw
  the scroll view frame to look just like a regular scroll view.
* Some fixes to layout of controls in file panels and minimum window size.
  There would be much more left to do...


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29663 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-23 11:26:53 +00:00
Stephan Aßmus
08ff393d50 Fix DraggableContainerIcon drawing after recent BControlLook method signature
change for DrawMenuBarBackground(). The borders are passed one position later.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29632 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-21 17:39:52 +00:00
Axel Dörfler
81824f60e5 * Auto mounting now works correctly for CDs and USB sticks, thus fixing bug
#2629.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29585 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-18 10:17:43 +00:00
Axel Dörfler
8f464bc9ad * Added support for automatic mount on media change. Not yet tested, though,
and probably only works for CDs as is (ie. not for USB sticks).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29584 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-18 08:57:46 +00:00
Stephan Aßmus
f5812f4b02 r28745 prevented overwriting the global type ahead string buffer from
an unrelated window. However, we broke unsetting the type ahead string on the
little info view. This fixes this again, the type ahead string never went
away.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29530 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-14 21:06:12 +00:00
Michael Lotz
492e224b8e * Update the signature of _kern_load_image(). It has been changed and therefore
the calls to it always failed.
* Check what error is returned and read the approprite details out of the
  message.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29516 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-14 14:16:17 +00:00
Axel Dörfler
4dabc2e663 * Fixed warning.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29512 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-14 13:47:36 +00:00
Stephan Aßmus
2ade87ffe7 Temporary fix for the ugly drag bitmaps when dragging icons from the Desktop.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29509 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-14 09:25:13 +00:00
Axel Dörfler
b32211a457 * r28871 turned around the sort logic for undefined attributes.
* Cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29486 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-12 23:01:45 +00:00
Rene Gollent
1c56dee2c4 We need to remove the node from our list when the pose is removed. Otherwise deleting, then recreating the same file will be rejected as a duplicate and not added to the view. Thanks to mmlr for reporting.
Small cleanups.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29450 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-08 21:34:09 +00:00
Rene Gollent
ccefc7ac9e Clear the node list when switching directories. Otherwise navigating out of a directory and back in single window mode will show no nodes whatsoever.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29419 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-07 01:50:26 +00:00
Rene Gollent
59160ac740 Fix gcc4 build. GCC 3 and up moved some of the SGI extension classes into a different namespace.
Fixes ticket #3524.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29418 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-07 00:48:00 +00:00
Rene Gollent
38f4625170 Rework this again due to flaws in the previous optimization - due to its use for things like sorting the visible pose list, it would rely on whatever pose column was being used for sorting, and as such would generate false positives when the view was being ordered by certain attributes. We now use an std::hash_set to track all the nodes that have been added to the current view and use that for a duplicate check instead. Also slightly boost the max number of models per chunk that we read.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29414 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-06 13:42:33 +00:00
Rene Gollent
847af0079c Second attempt at PoseView population optimizations: We still search for the pose in our list, but now rely on a binary search to do it instead, rather than the previous linear search. This considerably boosts population speed for large folders here, while still preserving correct behavior.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29395 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-03-04 03:54:29 +00:00
Alexandre Deckner
634596058d * Revert the changes in r29316 as it's now fixed upstream.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29319 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-02-24 21:41:32 +00:00
Alexandre Deckner
ea83c971c6 * Round mouse coords before doing BRegion ops for the transparent
selection rect, as BRegion behaves unpredictably with non-integral 
values (cf bebook).
  Fixes #1527


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29316 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-02-24 18:55:23 +00:00
Stephan Aßmus
887f9688a4 Improved the look of the icon label outline, at least the white text
version should look much better now. Not so sure about the dark text
version, but if you don't want that, just make sure your desktop bg
color is dark enough to get white text.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29310 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-02-24 11:07:22 +00:00
Jérôme Duval
08f9d40010 set widget outline to true on DesktopPoseView creation as default. It might not be set by the BackgroundImage code if there is none.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29283 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-02-22 13:38:57 +00:00
Rene Gollent
3291c58044 Revert the PoseView change from r29190. This is incorrect since the outline setting only applies to the desktop poseviews, and is explicitly set there by the backgrounds settings code in BackgroundImage.cpp. This fixes the font rendering artifacts reported in ticket #3467.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29277 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-02-21 23:41:48 +00:00
Rene Gollent
ec8c04cc2c Never show the copy cursor if the item being dragged is a volume or the disks icon. Fixes ticket #3468.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29276 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-02-21 23:07:38 +00:00
Alexandre Deckner
4712bc807c * Revert one the changes done in r29198 has it happen to be wrong. See #3450 and #3011
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29229 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-02-16 10:39:26 +00:00
Stephan Aßmus
2f86ba4557 Implemented a new look for the Haiku interface controls. It was
overheard that they looked too ninety-ish.
TODO: The code behind this is work in progress. The basic idea
is to extract all drawing code into a new class BControlLook,
of which there is a global instance be_control_look, instantiated
in InterfaceDefs.cpp. At the moment, all the old drawing code is
still there, and the usage of be_control_look is inside if-bodies
checking the instance against NULL. In another words, by not
instanitating be_control_look, you can revert back to the old look.
BControlLook's job is to provide reusable methods for drawing
certain types of frames, backgrounds and labels, so that application
developers can make controls that re-use the same drawing code
as built-in controls and adopt to changes made there. I have added
the notion of "borders". Each of the frame drawing methods can be
made to draw certain borders only, which is supposed to help when
controls shall visually attach. This feature is not fully explored
at all ATM.
TODO: Update BColumnListView header view and BStringItem text
spacing. Update other apps where it makes sense to use BControlLook.
For the moment, only Tracker and LaunchBox are updated. More...
NOTE: The new look is not very radically different, so that existing
apps do not immediately look too ugly or out of place.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29221 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-02-15 18:23:19 +00:00
Rene Gollent
95da064570 Some pose performance improvements by aldeck and myself:
1) We don't need to call FindPose() on every pose as we're freshly adding it,
and a duplicate should never happen in this circumstance (the FindPose() is still there if
Tracker is compiled in debug mode however.
2) Adjust the FSClipboard calls such that the locking is optional. This allows us to lock
once per CreatePoses group rather than once per pose.

Together these changes make for a significant performance improvement when it comes to
populating a large folder.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29198 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-02-14 19:54:47 +00:00
Jérôme Duval
71ed64b71b * Icon label outline is by default true. We take this into account on PoseView creation in Tracker, and when no image is selected in Backgrounds.
* This flag is still only settable when an image is selected.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29190 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-02-13 21:39:52 +00:00
Rene Gollent
c4d59015f6 Slight logic cleanup that prevents excessively rechecking the drop target in some instances.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29171 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-02-09 05:19:50 +00:00
Rene Gollent
a67852c554 Reset the cursor check state if we drag over a pose that's not a suitable DnD destination for the drag. Otherwise we'll reset the cursor back to the move state and never set to copy again unless we exit/reenter the window. Thanks to luroh for reporting.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29167 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-02-08 18:39:39 +00:00
Rene Gollent
81796bc0b3 Don't leak memory when aborting operations due to read-only volume.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29165 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-02-08 16:00:46 +00:00
Rene Gollent
c854c13348 Disallow move to trash and/or delete operations from read-only volumes. This fixes ticket #3421.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29163 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-02-08 14:33:22 +00:00
Rene Gollent
42fe9293f8 Tracker now alters the cursor to indicate the resulting FS op when drag and dropping files.
If the op is determined to be a copy, the copy cursor from Wonderbrush (thanks Stephan!) is
displayed. Otherwise, the default hand cursor is used to indicate move.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29155 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-02-08 01:05:34 +00:00
Joachim Seemer
4f3347b64b As discussed here:
https://lists.berlios.de/pipermail/haiku-commits/2009-February/014198.html
We decided on a distinction between path+filename and only the path to a file.
I changed the places a user is exposed to the issue, using the definition:
Path with filename:	"Path"
Path without filename:	"Location"


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29130 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-02-03 16:16:26 +00:00
Rene Gollent
8e1e99a333 Fix Create Link from context menu.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29109 a95241bf-73f2-0310-859d-f6bbb57e9c96
2009-02-01 16:25:30 +00:00