Commit Graph

68 Commits

Author SHA1 Message Date
Janus
1fad3c98b6 DiskUsage: avoid different crashes on rescan
* Fixes #9380, #11442.
2016-12-02 18:49:33 +01:00
Janus
04a05cf1f6 Diskusage: avoid glitch in "open with..." menu
* Fixes #13097.
2016-11-29 21:46:19 +01:00
Rene Gollent
8028ede7db Build: Add architecture rule for libshared.a.
- As suggested by Ingo, add libshared.a to the architecture name map.
  This allows it to be linked by its short name like other frequently
  used libraries.
- Adjust all Jamfiles referencing the lib accordingly.
2016-01-15 21:12:24 -05:00
Humdinger
d0ac609964 Use B_USE_WINDOW_SPACING
Use B_USE_WINDOW_SPACING as inset from contents to window border.
Some whitespace cleanup.
2015-11-07 17:40:16 +01:00
Philippe Saint-Pierre
8d449661ca CID 743867: Memleak in DiskUsage 2015-07-01 21:42:16 -04:00
John Scipione
93e5d9fa15 DiskUsage: Fix CID 1288122
In hrev48870 I made some updates to DiskUsage which accidentally caused this
CID.

Both the volume and item pointers were going out of scope without being deleted
in the error case leading to a resource leak. This commit seeks to fix the
problem by creating these objects as late as possible after the error checking.

tempVolume, which, as it's name implies, is created temporarily on the stack is
used instead of volume up until the point that AddTab() requires a more
permanent heap-stored volume pointer. Same goes for the VolumeView and
VolumeTab. name is created temporarily on the stack as well which works
because it is copied when passed into VolumeView constructor by the grandparent
BHandler before going out of scope.
2015-03-13 16:28:47 -04:00
John Scipione
fa05f35a2c DiskUsage: Skip virtual volumes
so we don't see the 4.00Kib system and config tab.
2015-03-06 13:51:55 -05:00
John Scipione
57ee63a5e5 DiskUsage: TabView flush to window border
http://postimg.org/image/izae7h1qd/
2015-03-06 13:51:55 -05:00
John Scipione
1b53ff0784 DiskUsage: Use an int32 instead of an int
for CountTabs() which returns an int32
2015-03-06 13:51:54 -05:00
John Scipione
58f4a50b33 DiskUsage: Style fixes 2015-03-06 13:51:54 -05:00
Adrien Destugues
23873c705c Missing braces in BMessageFormat format string.
Fixes #11678.
2014-12-30 22:32:51 +01:00
Adrien Destugues
5da82e3a10 DiskUsage: align tab focus mark with label.
Fixes #6905.
2014-12-03 08:41:09 +01:00
Adrien Destugues
03ad73fc87 More uses of BMessageFormat
ZipOMatic, DiskUsage, MediaConverter, MediaPlayer, ShowImage,
WebPositive, Screen preferences, Tracker, string_for_size.

Thanks to KapiX for reporting those!
2014-11-24 15:42:52 +01:00
Adrien Destugues
2824c5d3a4 Fix various typos and inconsistencies in strings
DiskProbe, DriveSetup, Icon-O-Matic, Installer, Login,
PackageInstaller, Screenshot, Translation Inspector, BootManager,
CharacterMap, CodyCam, BPrintJob

DiskUsage: removed useless translation, used only for layouting purposes

Thanks to KapiX for spotting these problems.
2014-11-24 09:42:26 +01:00
Adrien Destugues
d6bd833865 Fix ICU message syntax
This apparently led to a crash in ICU, reported on the mailing list.
2014-10-12 11:43:16 +02:00
Adrien Destugues
961fdd8cc3 BMessageFormat: parse the pattern at construction
* Instead of parsing the pattern everytime Format() is called, parse it
only once when the object is created.
* Adjust all callers to make use of the feature and reuse the instance
as much as possible. This also allows calling B_TRANSLATE only once
instead of everytime the formatting needs to be done. We use either a
static instance (when the message pattern is constant) or a field (when
it is not known to be constant).
* Since the BMessageFormat instances are now reused, add locking to
avoid race conditions (ICU itself is thread safe, but the format pattern
is recreated when the locale is changed)
2014-10-08 15:12:48 +02:00
Adrien Destugues
be93029899 More uses of BMessageFormat. 2014-10-08 13:17:17 +02:00
Oliver Tappe
220d040227 Use libstdc++, libsupc++ and libgcc from gcc_syslibs.
* Instead of faking libstdc++.so from libstdc++.a, use libstdc++.so
  from the gcc_syslibs build feature for everything except x86_gcc2.
* Use libgcc_s.so from the gcc_syslibs build feature for everything but
  x86_gcc2 (which still carries libgcc as part of libroot.so).
* Drop filtering of libgcc objects for libroot, as that is no longer
  necessary since we're only using libgcc-as-single-object for libroot
  with x86_gcc2, where the filtered object file doesn't exist. Should
  the objects that used to be filtered cause any problems as part of
  libgcc_s.so, we can always filter them as part of the gcc build.
* Use libsupc++.so from the gcc_syslibs build feature for everything but
  x86_gcc2.
* Adjust all Jamfiles accordingly.
* Deactivate building of faked libstdc++.so for non-x86-gcc2. For
  x86_gcc2, we still build libstdc++.so from the sources in the Haiku
  source tree as part of the Haiku build .
* Put gcc_syslibs package onto the image, when needed.
2014-08-13 13:32:44 +02:00
John Scipione
5443e035e8 DiskUsage: Open file/folder on cmd-click, zoom on regular click. 2014-06-05 17:55:42 -04:00
John Scipione
eef00544a4 DiskUsage: Style fixes. 2014-06-05 17:52:00 -04:00
Siarzhuk Zharski
372072c899 StyledEdit/DiskUsage/DriveSetup post-hrev46520 fixes
* StyledEdit - make Find/Replace windows non zoomable, select the search
  string view on showing the window for repetitional search;
* Devices - fix plain property list background - to standard one and
  restore read-only state of this pane;
* DriveSetup - remove radio-mode of drive list context popup menu;
* DiskUsage - SetLowColor to parent background to avoid small text
  rendering issue.

Many thanks to Sergei Reznikov for testing and pointing issues out.
2013-12-11 20:44:16 +01:00
Freeman Lou
7470dfe2d3 DiskUsage: Change background color to parent one
* Fixes #7985.

- GCI 2013
2013-12-10 21:25:17 +01:00
Ingo Weinhold
cf70d345b2 Merge remote-tracking branch 'haiku/master' into package-management
This reverts 8f7f28a7c3 (OpenGL: Upgrade
to
Mesa 9.2).

Conflicts:
	build/jam/BuildFeatures
	build/jam/HaikuImage
	build/jam/OptionalPackages
	build/scripts/build_cross_tools_gcc4
	src/add-ons/opengl/swpipe/Jamfile
	src/apps/diskusage/Jamfile
	src/kits/tracker/ContainerWindow.cpp
	src/kits/tracker/DeskWindow.cpp
	src/kits/tracker/Jamfile
2013-09-13 01:02:28 +02:00
Ingo Weinhold
b0944c78b0 More work towards hybrid support
* All packaging architecture dependent variables do now have a
  respective suffix and are set up for each configured packaging
  architecture, save for the kernel and boot loader variables, which
  are still only set up for the primary architecture.
  For convenience TARGET_PACKAGING_ARCH, TARGET_ARCH, TARGET_LIBSUPC++,
  and TARGET_LIBSTDC++ are set to the respective values for the primary
  packaging architecture by default.
* Introduce a set of MultiArch* rules to help with building targets for
  multiple packaging architectures. Generally the respective targets are
  (additionally) gristed with the packaging architecture. For libraries
  the additional grist is usually omitted for the primary architecture
  (e.g. libroot.so and <x86>libroot.so for x86_gcc2/x86 hybrid), so that
  Jamfiles for targets built only for the primary architecture don't
  need to be changed.
* Add multi-arch build support for all targets needed for the stage 1
  cross devel package as well as for libbe (untested).
2013-08-01 08:54:06 +02:00
Philippe Saint-Pierre
da1f251a8f DiskUsage: drawing artefact in TabView 2013-07-17 12:01:26 -04:00
Philippe Saint-Pierre
fffc0e2a7b DiskUsage: reuse string_for_size in libshared.a 2013-07-13 14:19:09 -04:00
Philippe Saint-Pierre
3fe416173c Tracker add-on shortcuts, move resource to BEOS: namespace 2013-07-13 14:19:09 -04:00
Philippe Saint-Pierre
41e6527c1f Tracker addons: strip shortcut from name, instead use resource 2013-07-11 12:38:41 -04:00
Humdinger
2e2e8f7d2e Fixed case of GUI strings. 2012-12-23 18:30:02 +01:00
Philippe Saint-Pierre
46db18d199 DiskUsage: Truncating of tabs could lead to deadlock (#9170) 2012-11-17 22:00:47 -05:00
Philippe Saint-Pierre
5dcd116f40 DiskUsage: avoid leaking the saved scan snapshot 2012-11-14 23:07:22 -05:00
Philippe Saint-Pierre
3e52a3d5e5 DiskUsage: added ability to cancel an ongoing scan. fixes #6801.
Also, progress now goes from 0.0 to 1.0 rather than from 0.00 to 100.00
(to avoid a * 100, followed by a / 100)
2012-11-14 22:33:44 -05:00
Philippe Saint-Pierre
9029fc709b DiskUsage: update status view after zoom in or zoom out. fixes #6756. 2012-11-14 22:33:44 -05:00
Philippe Saint-Pierre
a4ef1e81ce DiskUsage: remove path monitoring and "outdated view" notification
Was unreliable, too many files to monitor (would exceed too easily the 4096 files limit).
2012-11-14 22:33:44 -05:00
Adrien Destugues - PulkoMandy
4c3295fc92 Tweak DiskUsage pie view colors and drawing
* Use colors from http://haiku-os.org/files/downloads/2007-03-20_haiku-color-palette.png
 * The pie view used a simple multiplication to lighten the colors, leading to overflows. Use tint_color instead
 * The outline of each pie slice was drawn with lines, which did not align perfectly. Use StrokeArc with a slightly bigger pen size than the colored area instead.

Screenshot of the result:
http://pulkomandy.tk/drop/diskusage.png/
2012-08-15 10:32:04 +02:00
Oliver Tappe
546208a539 More catalog-related cleanup.
* rename B_TRANSLATE_CONTEXT to B_TRANSLATION_CONTEXT and
  B_TRANSLATE_WITH_CONTEXT to B_TRANSLATE_CONTEXT, squashing a TODO
* adjust all uses of both macros in Haiku's source tree
* use correct header guard for collecting/Catalog.h

The renamed macros require adjustments to all external applications
using catalogs.
2012-04-16 21:31:22 +02:00
Philippe Saint-Pierre
a9e957e2de DiskUsage: Implement truncation in tabs labels
* To allow more devices to be shown and accessible within
  DiskUsage, truncate the columns names if necessary.

Might help but not quite fix #6800.
2011-11-13 22:20:25 -05:00
Rene Gollent
f6df6995b6 Apply patch by Olivier Coursiere that fixes #8075: the color index variable
wasn't constrained to the size of the color array, leading to an overflow +
crash when a large number of files were scanned. Thanks!



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@43036 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-10-31 17:07:47 +00:00
Oliver Tappe
e54b10160f Close #3223 with patch provided by Humdinger (which I adjusted to the current state of the code).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42964 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-10-29 16:06:08 +00:00
Jonas Sundström
560ff4478d Use resource definition files instead of DoCatalogs rule. Rename B_TRANSLATE_APP_NAME and related macros to the more generic B_TRANSLATE_SYSTEM_NAME, to also fits add-ons, folders, etc, and make 'System name' its standard context. Change CodyCam and PoorMan's app signatures to match the overall x-vnd.Haiku-App pattern. Some clean-up. Make SlideShowSaver build again.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41103 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-03-25 22:13:48 +00:00
Jonas Sundström
066522e87b Localization changes. Use of B_TRANSLATE_APP_NAME(). Small cleanups.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40949 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-03-14 14:41:13 +00:00
Philippe Saint-Pierre
95780b6475 Allow DiskUsage to be used as a Tracker add-on again.
Fixes #7343.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40859 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-03-07 19:13:21 +00:00
Philippe Houdoin
372bd6a113 Use be_control_look to draw the progressbar. The previously hardcoded one was
following the BeOS look, not our.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40776 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-03-02 11:17:19 +00:00
Philippe Saint-Pierre
471b5ec496 DiskUsage :
* Reduce the height of the StatusView. It was way taller than necessary.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40772 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-03-02 00:22:24 +00:00
Philippe Saint-Pierre
8d779aa8df DiskUsage :
* add two missing break; (CID 3301, 3302)
  * replace strcpy, strcat and sprintf by strlcpy, strlcat and snprintf
    (CID 6804, 6805, 6806, 6807, 6808, 8962, 8963)
  * remove a PrintToStream (left by accident for debugging purposes)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40631 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-02-23 01:08:25 +00:00
Siarzhuk Zharski
973f8e214d Applied yet another localization patch from Jorma Karvonen. Fixes #7169.
Beside of localization task some refactoring was performed:
- strings, stored previously in resources were moved from resource definition
  file to cpp files at the place of using;
- cleanup of resource definitions and Common.cpp/Common.h.

Additionall tasks, made by S.Zharski:
- the rests of resource handling tasks were purged out from Common.cpp/Common.h;
- Common.h renamed to DiskUsage.h;
- the rests of code from Common.cpp merged into DiskUsage.cpp;
- the preprocessor tricks and magics targeted mainly for resources support
   were removed;
- some code style fixes and "internationalization style" fixes were made.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40493 a95241bf-73f2-0310-859d-f6bbb57e9c96
2011-02-14 18:26:15 +00:00
Philippe Saint-Pierre
dde4ac4386 DiskUsage enhancement (ticket #3520)
* the volume are now displayed in tabs, mounting and unmounting volume adds and remove tabs accordingly
 * the infos (file size, etc..) are now displayed below the graph
 * node monitoring tells you when your current view is outdated. (the ticket suggested to adjust the view automatically, but I'll wait for comments on this first).
 * Drag&Dropping a file on the graph changes the tabview to the tab representing the volume owning that file.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@38958 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-10-12 23:50:09 +00:00
Joachim Seemer
7fd93693fd Use binary prefixes (KiB, MiB, GiB...). Fixes #6551.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@38533 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-09-05 08:58:09 +00:00
Oliver Tappe
4b920fd031 * fix warnings in diskusage
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@38269 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-08-19 16:28:42 +00:00
Wim van der Meer
6020035bb0 Fixes a ''virtual status_t BMenuItem::Invoke(BMessage*)' was hidden' warning.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37332 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-07-02 03:16:03 +00:00