Commit Graph

54586 Commits

Author SHA1 Message Date
Axel Dörfler
f7c2983edc HaikuDepot: change window frame setting.
* Moved entirely into MainWindow.
* Moved duplicated code into separate methods.
* Resize the main window on larger screens by default, as we can make
  use of the extra space.
* Use BWindow::MoveOnScreen() instead of make_sure_frame_is_on_screen()
  as the former has more info. And is even smarter now as it can
  optionally resize windows to fit on screen.
* Center window on screen by default (ie. when there are no settings).
2015-09-08 17:58:02 +02:00
Axel Dörfler
bafcf01610 DiskProbe: improved layout scaling.
* Don't use a fixed size font for the header controls, but one that
  depends on the default plain font size.
* Minor cleanup.
2015-09-08 17:56:22 +02:00
Stephan Aßmus
7d8d7785c1 Text framework: Added TextEditor::Replace()
Call Replace() on TextDocument, so that there are not two edits later
on once UndoableEdit stuff is supported.
2015-09-06 23:09:36 +02:00
Stephan Aßmus
41bd20b06b Text framework: Add TextListener in TextDocumentLayout...
... and invalidate based on TextChangedEvents. I am not yet sure whether
TextChangeEvent needs separate counts for removed and changed paragraphs.
It is most likely not yet correct and may either update too many paragraph
layouts or miss updating some at the end.
2015-09-06 23:07:09 +02:00
Stephan Aßmus
4a96bcdafa Text frame work: Implement sending TextChangedEvents
TextDocument:
 * Moved implementation of Remove() and Insert() into private methods.
 * Reimplement all public Insert() methods and Remove() on top of Replace().
 * In Replace(), send a TextChangedEvent. Added TODO for sending a
   TextChangingEvent, although at this point, I am not sure if it will be
   needed at all.
2015-09-06 23:03:34 +02:00
Stephan Aßmus
f6e5131227 TextDocumentTest: Make document editable. 2015-09-06 23:02:51 +02:00
Stephan Aßmus
87136732d0 HaikuDepot: Fixed wording in a comment. 2015-09-06 21:51:24 +02:00
Stefano Ceccherini
ce27f9612e Implement ClipToPicture inside a BPicture. Not working yet.
BView::ClipToPicture doesn't work anymore, when nested inside a BPicture,
This happened when its implementation was moved server-side.
2015-09-05 21:35:54 +02:00
Humdinger
8ebeba656c Updated Web+ bookmarks.
Added BeSly software repo.
2015-09-05 19:17:10 +02:00
Michael Lotz
83dc74af93 BPicture: Fix archive constructor on 64 bit.
The int32 was cast to a ssize_t which has a different size on 64 bit,
therefore clobbering the stack.

Also remove the use of basic type references in arguments, which
probably was the reason for doing the above in the first place.
2015-09-05 18:13:34 +02:00
Michael Lotz
d64c7086d5 Various whitespace cleanup only. 2015-09-05 16:09:33 +02:00
Michael Lotz
8b9ec55606 BPicture: Fix archive constructor.
The cleanup commit df48d3f9a8 broke
constructing a BPicture from an archive due to an incomplete rename.
The passed in BMessage was used as the data buffer instead of the
extracted data field.

Fixes the application side crash of #12340. Seeing how long this was
broken without anyone noticing, the feature doesn't seem to be very
popular.
2015-09-05 16:09:32 +02:00
Michael Lotz
4176076be1 app_server: Port ServerPicture to the new PicturePlayer API.
This allows for bounds checks on strings and bitmap data to avoid
crashing due to corrupted user data. It also avoids copying the data
where possible.
2015-09-05 16:09:32 +02:00
Michael Lotz
eec73693e0 PicturePlayer: Rework to be more safe against corrupted data.
This introduces a more sane API (currently private) that allows for
safer and possibly more efficient implementations:

* It uses a struct of named and typed function pointers instead of just
  a void pointer array. This adds type safety to the callbacks so the
  compiler can figure out if things match up before subtle bugs get
  introduced.
* It provides bounds for all strings/buffers passed to the callbacks.
* It uses const references instead of implicitly copying arguments.
* It folds stroke_x/fill_x pairs into draw_x functions with a fill
  argument to reduce the amount of functions needed.
* It uses unsigned values where negative values make no sense.

The old API has been implemented on top of the new one using adapter
functions. It makes copies of all data passed to the callbacks which
effectively keeps the picture data from being modified. This matches
with the R5 behaviour.

This also reimplements the buffer parsing to be safe against corrupted
data by validating that the types actually fit in the provided sizes
and buffers (using a templated reader).

Since this class is used from the app_server with user provided data,
making it more safe is important even though it comes with a slight
overhead (replicating R5 behaviour, i.e. crashing the app_server when
corrupted data is fed, doesn't seem very appropriate here).
2015-09-05 16:09:31 +02:00
Adrien Destugues
5a87d490f5 Fix implementation of _res.
While not thread-safe, it should still be possible to use it in
non-threaded programs, or with locking on the application side.

The "thread-safe" implementation we got from NetBSD called abort(),
which is not a good solution. Restore the non-thread-safe
implementation, which should still work.

Fixes issues in openssh and mtr, and possibly other ported apps.
2015-09-05 12:17:46 +02:00
Humdinger
bf70e50b07 Updated Slime Volley package
Now with icon, app-signature, and settings saved in B_USER_SETTINGS_DIRECTORY.
2015-09-05 11:17:13 +02:00
autonielx
f3565aaab0 Update translations from Pootle 2015-09-05 06:40:57 +02:00
Alexander von Gluck IV
8248d96a06 AHCI: Begin simulating SCSI Inquiry with VPD data
* Needed for SCSI level access to trim maximum block sizes.
2015-09-04 19:30:34 -05:00
Rene Gollent
a1e25f862c Mail: Fix gcc4 build.
- Fix typo in forward declaration.
- Add missing include for snprintf.
- Add missing virtual destructor on QueryListener abstract class.
2015-09-04 16:57:06 -04:00
Axel Dörfler
9ed8f48498 Mail: show icons only setting works again.
* It will show the label as tool tip when the labels are hidden.
2015-09-04 17:33:51 +02:00
Axel Dörfler
6b8712663a BToolBar: made FindButton() public. 2015-09-04 17:33:46 +02:00
Axel Dörfler
50d381e862 Mail: use layout version of BMenuBar.
* Fixes layout issue: the minimal size was incorrect.
* Moved variable declaration to where it is actually used.
2015-09-04 17:33:41 +02:00
Axel Dörfler
31c65be109 Mail: fixed crash on resend.
* Seems to have been there for quite some time. Probably a good
  reason to remove that feature altogether.
2015-09-04 17:33:36 +02:00
Axel Dörfler
15c1056242 BMailSettings: removed debug message dump. 2015-09-04 17:33:32 +02:00
Axel Dörfler
62c1b01661 Mail: temporary workaround for the label placing issue.
* Does not work for all font sizes.
2015-09-04 17:33:27 +02:00
Axel Dörfler
4182c53bc4 Mail: change look of disabled text controls.
* Added HeaderTextControl that draws the text in black, and uses the
  panel background without a frame when it's disabled. Only the label
  is still drawn as disabled.
* Changed AddressTextControl to behave in the same way.
* The date view is now a HeaderTextControl, too.
* Unfortunately, the label is not vertically aligned with the contents.
2015-09-04 17:33:22 +02:00
Axel Dörfler
7bdee8beab BEmailMessage: added missing const, Date() returns time_t.
* Added missing const to some getter methods.
* Date() now tries to parse the date of the mail, and return it as
  a time_t; you can still retrieve the actual string via
  HeaderField("Date") if you have to.
* Mail now shows the time in the local time zone, and with the
  current locale.
2015-09-04 17:33:17 +02:00
Axel Dörfler
66078c7911 BMailComponent: made a few methods const. 2015-09-04 17:33:12 +02:00
Axel Dörfler
19d8cb703c BDate: added time_t constructor.
* This class is pretty much useless as it is.
2015-09-04 17:33:07 +02:00
Axel Dörfler
cc7e5aac40 Mail: fAccount text control is no longer used. 2015-09-04 17:33:03 +02:00
Axel Dörfler
8b1aaf348c Mail: properly disable prev/next buttons without Tracker.
* The prev/next buttons will only work when invoked via an actual
  mail file from Tracker.
2015-09-04 17:32:58 +02:00
Axel Dörfler
d891923650 BMenuField: use layout rect for the label.
* Instead of just laying it out as without the layout API.
2015-09-04 17:32:53 +02:00
Axel Dörfler
df946869a1 Mail: work in progress to use the layout API. 2015-09-04 17:32:48 +02:00
Axel Dörfler
e047b40a2f Interface Kit: use different spacing constants.
* While this breaks binary compatibility with earlier Haiku releases,
  use values that are less likely to clash with actual use cases.
* Specifically, using a negative spacing is one way to get rid of the
  border of BScrollViews, to put them into a window neatly.
* Also, BControlLook now uses a switch to resolve them.
2015-09-04 17:32:44 +02:00
Axel Dörfler
fa89878a70 Terminal: renamed some variables for clarity.
* Unless they really have no meaning beyond serving as an index, you
  should avoid naming your variables just i, j, k, l.
2015-09-03 21:30:43 +02:00
Axel Dörfler
52e43a20be Terminal: replaced positioning with BWindow::MoveOnScreen().
* The previous mechanism was pretty crude, and didn't work that well.
2015-09-03 21:30:40 +02:00
Axel Dörfler
ebf4cbe6e7 Incredibly smart BWindow::MoveOnScreen() method added.
* Makes sure that the window is as complete as possible on screen.
2015-09-03 21:30:37 +02:00
Axel Dörfler
b7d0120074 Terminal: Added "Save as defaults" back.
* It's still convenient to have.
* Furthermore, the distinction between when settings are stored is hard
  to grasp otherwise.
* Plus, adopting the current window size is now much more straight forward.
2015-09-03 21:30:34 +02:00
Humdinger
9a1b63b19f Update QuickLaunch package to v0.9.12
Changes in v0.9.12:

*	Make the "Window always on top" optional. Not everyone was pleased with
	that change of v0.9.11...
*	Also fix the formerly not usable file dialog when adding files/folders to
	ignore. It was hidden behind the always-on-top window.
*	Added Italian localization, thanks Barrett!
2015-09-03 19:20:59 +02:00
Automatic Committer
db3fda16ea Update pci.ids from pciids.sourceforge.net 2015-09-03 05:20:31 +02:00
Humdinger
0dd0c8a4ae Update Slime Volley game.
Wasn't installable before, the PROVIDES wasn't correct.
Hope it works now...
2015-09-02 13:59:51 +02:00
miqlas
c3dfa1d9d0 Solarized Dark and Light color scheme for Terminal
Signed-off-by: Alexander von Gluck IV <kallisti5@unixzen.com>
2015-09-01 17:29:19 -05:00
Alexander von Gluck IV
0cd624b89c AHCI: Begin adding SCSI VPD query support. 2015-09-01 17:13:04 -05:00
Dario Casalinuovo
38e3fbe389 BMediaRoster: Remove possibly confusing debug prints
* Thanks to Axel and Rene for reviewing!
2015-09-01 15:08:57 +02:00
Dario Casalinuovo
7d337b23b7 BMediaRoster: Reintroduce the undertaker class
* This has been necessary due to the undefined call order of
of static objects. Fixes #12315.
* The bug has been caused by the linker which free unused resources,
making the BMediaRoster to run in a zombie state. In this state
anything such as a message could make the looper to crash.
* The class is reintroduced with some differences though, we are
going to protect it from another thread calling Roster() while the
BMediaRoster is quitting and implement BMediaRosterEx::Quit.
* Unregister registrar notifications before we quit our thread. Avoid
to uninitialize anything from QuitRequested as it may cause problems.
2015-09-01 15:08:57 +02:00
Michael Lotz
a33d19b0a4 Update haikuwebkit packages to 1.4.12 on x86[_(gcc2|64)]. 2015-08-30 23:10:51 +02:00
Adrien Destugues
278af8e281 ffmpeg: check against correct version constants.
54.23.x is ffmpeg 0.11, which still has "CodecID" (and x>0).
2015-08-30 18:00:08 +02:00
Adrien Destugues
f618c89e17 ffmpeg: detect the library version the right way.
* Fixes the build by detecting the library version using the provided
constants, instead of guessing from the compiler version.
2015-08-30 17:33:00 +02:00
Adrien Destugues
9e5c694668 ffmpeg plugin: remove more deprecated functions.
These were all deprecated between releases 0.6 and 0.10 of ffmpeg,
except for one change (renaming of CodecID to AVCodecID) which we can
work around with a typedef. The deprecated functions were still
available in 0.11, but were removed later on after several years of
deprecation.

This makes it possible to build our plugin with any ffmpeg version
between 0.10 and 2.7, so we can now experiment with updating to 2.7 at
least for the gcc4 builds.
2015-08-30 16:36:08 +02:00
Adrien Destugues
0f7e19ce7e ffmpeg plugin: add support for MOD and other "tracked music"
* ffmpeg can handle these through ModPlug
* By default, ffmpoeg will not try these formats because the way to
detect them are a bit unsafe (4 bytes at a particular offset in the file
serve as an identifier). So, hint the sniffing by giving it a filename
of ".mod" to get modplug to be used. This does not affect sniffing in
the regular way for other formats.
* Add some common tracked music formats to the muxer table.
* Fix some tracing to use current (as of ffmpeg 0.10) function names and
because some variables were renamed.
2015-08-30 16:36:06 +02:00