Commit Graph
100 Commits
Author SHA1 Message Date
Stephan Aßmus bc1e082b56 BHttpRequest: Treat incomplete downloads as error
When BSocket::Read() returns 0, it was treated as
a finished transfer. This is OK when we don't know
the content length, but when we do, there is no reason
not to bubble up the error. Return B_IO_ERROR in this
case.

Change-Id: I68801dbbb85bcfd2e7aa68fd6a9ded6304e82b19
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3621
Reviewed-by: Adrien Destugues <[email protected]>
Reviewed-by: waddlesplash <[email protected]>
2021-01-19 17:05:40 +00:00
Stephan Aßmus 7e677f6465 Package Kit: Delete downloads failing the checksum check
Change-Id: I3a7a914ea88e7b7b5bcc79160f46a9b4fcbba01b
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3619
Reviewed-by: Adrien Destugues <[email protected]>
2021-01-18 20:27:12 +00:00
Stephan Aßmus 60c165a53c BSecureSocket: Treat SSL-zero-return as B_IO_ERROR
Somehow B_CANCELED doesn't seem to convey the correct
meaning. Using B_IO_ERROR will also fit to the recent
changes in the Package Kit and will trigger a re-try of
package downloads.

Change-Id: I58c4d4faa705e6519e0ff9ec7c4654a6151e5486
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3635
Reviewed-by: Adrien Destugues <[email protected]>
2021-01-16 16:32:32 +00:00
Stephan Aßmus 8c812f2d63 BHttpRequest: Fix the cast and therefor GCC2 build
Change-Id: Ia0729a20d143721d395d5d50719e87b99b76bb05
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3614
Reviewed-by: Stephan Aßmus <[email protected]>
2021-01-09 15:56:08 +00:00
Stephan Aßmus f866207173 Package Server: Handle existing files when commiting transaction
Package files to be committed may already exist in the packages folder,
there is no good reason to fail the transaction. These may be packages
which are not activated, or there may be other reasons. While I have
not investigated how this situation may form, I don't see a good reason
to spend the time. Simply compare the contents of the existing file
with the file from the transaction, only fail if they are different.

Change-Id: I2a574df38385c8dead8bac2beace94436d43760a
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3597
Reviewed-by: Adrien Destugues <[email protected]>
2021-01-05 17:24:51 +00:00
Stephan Aßmus a0d1cbb95d Revert "netfs: Take advantage of HashKeyPointer."
This reverts commit 279470d553.

Reason for revert: Commited in wrong order.

Change-Id: I1163b12728f19aee4506c95512d0afdea0433362
Reviewed-on: https://review.haiku-os.org/c/1046
Reviewed-by: Stephan Aßmus <[email protected]>
2019-02-13 10:50:02 +00:00
Stephan Aßmus 57e2488804 Get rid of special B_OP_COPY implementation for rendering text
Since BeOS had no anti-aliased drawing except for text, it didn't
matter whether drawing diagonal lines (for example) in B_OP_COPY
or B_OP_OVER. Applying the meaning of B_OP_COPY strictly to everything
else would have broken pretty much every existing BeOS, resulting
in broken drawing for anything but straight lines and rectangles.
The solution was to treat B_OP_COPY just like B_OP_OVER *except*
for text rendering, where we could be compatible with the BeOS
behavior. Nevertheless, one can sometimes observe apps using B_OP_COPY
where they /should/ be using B_OP_OVER for rendering text, resulting
in white edges around the glyphs where the actual LowColor() does not
match the current background on which the text is rendered.
There is however a problem when glyphs in a string overlap. Some
fonts have overlapping glyphs by default (handwriting, etc). With
the LCD sub-pixel filtering, this problem is visible even in fonts
where glyphs don't overlap normally, for example 'lt'. The leftmost
pixel of the 't' is smeared due to the filtering and produces an
almost transparent pixel which is rendered (using the low color as
the background) on top of the 'l'. To fix this, one would have to
render the string into an alpha mask buffer first, and then blend it
all at once using B_OP_COPY. This however defeats the point of
B_OP_COPY, which is to be a performance optimization. So instead, I
opted for the solution that is already in place for everything else,
which is to make B_OP_COPY behave like B_OP_OVER. For the case that
this would have produced a difference, i.e. rendering with the solid
high color, one needs to clear the background using the low color,
before rendering text, or it would have looked broken. So in practice,
there cannot be a difference.

Change-Id: I4348902ae754507f1429e0a9575f03d8ecbce333
Reviewed-on: https://review.haiku-os.org/c/877
Reviewed-by: Adrien Destugues <[email protected]>
2019-01-14 08:33:46 +00:00
Stephan Aßmus 315ab3328e Small test-app playing ground for text rendering
The test app currently shows a number of problems in text rendering

 * Above a certain font-size, there is no glyph caching, which
   also means there is no sub-pixel filtering. It is actually
   the same problem right now for all vector-drawing. It uses the
   sub-pixel rendering pipeline, but without any filtering.
 * This test feels very sluggish. Something is going on which seems
   to be very unoptimized. To be observed when resizing the window
   and causing redraws.
 * Overlapping glyphs are handled wrongly in B_OP_COPY mode. The
   problem is that glyphs are drawn one at a time, but B_OP_COPY
   also draws the background color. In case some pixels already
   drawn with the text color by one glyph are drawn again by the
   next glyph, but with the background color, then it looks like
   gaps in the text. This problem has always existed. With the
   double filtering that was recently fixed, it was just especially
   visible, since, due to the smearing, it was much more likely that
   there were extra background pixels at the left side of glyphs.
   (Right side, too, but without visual effect.) Of course not
   completely transparent pixels, those are not drawn, but almost
   transparent pixels.

Change-Id: If590a4c93983c5a3ff0772c19074c408be8e1e74
Reviewed-on: https://review.haiku-os.org/c/871
Reviewed-by: Adrien Destugues <[email protected]>
Reviewed-by: waddlesplash <[email protected]>
2019-01-11 16:51:27 +00:00
Stephan Aßmus 54333f5172 Don't do LCD subpixel filtering twice
The currently included version of libfreetype already has the LCD
subpixel filter turned on by default. With the switch from my
"averaging filter" back to Adrej Spielmann's filtering, there was now
another filtering being done on top of what Freetype already does.
There also seemed to be a problem with the left edge of cached
glyph bitmaps, which I didn't bother to look into. The visual result
of this change is that text looks much crisper, and the display
bugs at touching glyphs is gone.

On the other hand, LCD sub-pixel rendering is still turned on
globally, i.e. for all vector drawing, and for uncached rotated
text. The Freetype filtering is not applied there. This problem did
not exist in my "average filter", since it happened at the scanline
rendering level, not only for cached glyph bitmaps. It is however
not a regression introduced by this commit. It needs to be fixed
separately.

Change-Id: If93c2b85ed479670e6679227984fd8d9f77c11f6
Reviewed-on: https://review.haiku-os.org/c/855
Reviewed-by: Stefano Ceccherini <[email protected]>
Reviewed-by: waddlesplash <[email protected]>
2019-01-06 18:43:49 +00:00
Stephan Aßmus 954a0a0c33 Fix some cases of updating draw state while recording a BPicture
* Also implemented recording DrawString(string, length,
   BPoint[] locations), which was previously not recorded at all.
 * Also implemented playing back recently added drawing commands
   in PicturePlayer.cpp. I don't quite understand what this is
   actually used for, but it seemed it was forgotten. I just followed
   the pattern already established in the code.
 * The other important bit in this change is to update the pen
   location when it is needed while recording a BPicture. Often
   the BView will use PenLocation() in order to transmit drawing
   commands to the app_server which use absolute coordinates only.
   This isn't actually so nice, since it means the client has to
   wait for the server to transmit the current pen location. If there
   were dedicated link-commands for pen-relative drawing commands,
   the client could just keep sending without waiting for the server.
   In any case, the app_server needs to update the pen location in
   the current DrawState and even the DrawingEngine even while
   recording a picture, because some next command may need up-2-date
   state information, such as the font state and the pen location.
 * I have not yet tried to find /all/ instances where the DrawState
   needs to be updated while recording. This change should repair
   /all/ font state changes, all versions of drawing a string, and
   all versions of StrokeLine().

Change-Id: Ia0f23e7b1cd058f70f76a5849acb2d02e0f0da09
Reviewed-on: https://review.haiku-os.org/c/817
Reviewed-by: Stephan Aßmus <[email protected]>
2019-01-06 00:06:56 +00:00
Stephan Aßmus f8550e541b Added two DrawStringDry() versions for obtaining pen location only
When recording into a BPicture (ServerPicture, actually), one cannot
simply record the commands only, when the drawing itself would modify
state. This affects all drawing commands that change the pen location.
Therefore it is necessary to have a way to "dry-run" drawing a string
in order to know the pen location that would result. This is what
these two new methods help achieve.

Change-Id: Ic399a5513f18c12c16c0ab10a55e768c1b30e4e0
Reviewed-on: https://review.haiku-os.org/816
Reviewed-by: Rene Gollent <[email protected]>
2019-01-03 18:19:02 +00:00
Stephan Aßmus f10faf61ac Change DrawString() and add StrokeLine() to reveal wrong pen-position
Change-Id: Iec584657741f2bb682bff557dcd3b733a9166c7c
Reviewed-on: https://review.haiku-os.org/815
Reviewed-by: waddlesplash <[email protected]>
2019-01-02 21:21:52 +00:00
Stephan Aßmus 1876ba00cd DrawState: Return mask from ReadFontFromLink()
When changing the font state, a uin16 mask at the beginning of the
commands encodes which font parameters are transmitted in the link
data. Return this mask, so that one can know what parameters have
changed in the DrawState's ServerFont.

Change-Id: I52a9a665aac8eb0e6505193eba32c4b137846c78
Reviewed-on: https://review.haiku-os.org/814
Reviewed-by: waddlesplash <[email protected]>
2019-01-02 21:21:52 +00:00
Stephan Aßmus 3da9a05272 TextDocumentTest: Embed text view into scroll view
Work in progress... text view does not yet control the scroll bars
properly when the contents change.
2015-09-26 01:48:41 +02:00
Stephan Aßmus da16a92894 Model: Pull changelogs from the package infos 2015-09-26 01:48:36 +02:00
Stephan Aßmus 17dd011a5f WebAppInterface: Request to receive changelogs 2015-09-26 01:48:31 +02:00
Stephan Aßmus 16f524c59b PackageInfoView: Update on changelog changes
Also re-order the bitfield test such that each sub-view is only
updated once per package changed message.
2015-09-26 01:48:27 +02:00
Stephan Aßmus 5f80d48a76 TextDocument: Extended comment in _Insert(). 2015-09-20 22:18:10 +02:00
Stephan Aßmus f890fab65b TextDocument: Change _Insert() to use TextDocument
In preparation for implementing Undo/Redo support, we need _Insert() to
take a TextDocument instead of a BString, CharacterStyle and ParagraphStyle.
When a chunk of the TextDocument has been removed, we need to be able to
Insert() that as part of the Undo operation. Not well tested, but typing
still works.
2015-09-20 22:17:26 +02:00
Stephan Aßmus 2e2ff27a92 Paragraph: Added EndsWith(BString) 2015-09-20 22:17:21 +02:00
Stephan Aßmus 9a8dd79cc2 TextDocumentLayout: Use Invalidate() instead of InvalidateParagraphs()
Added TODO about which data the TextChangedEvent should have in order to
know how to respond in the TextDocumentLayout. For now, update all paragraphs
in the layout, add new ones as necessary, and remove the ones we have in
excess by using Invalidate().
2015-09-20 22:17:17 +02:00
Stephan Aßmus 1fa37d5af8 HaikuDepot: Text: Fix regression for B_SELECT_ALL
An Invalidate() was removed, since I originally planned to remove the need
to invalidate on selection changes, but then saved it for later.
2015-09-20 22:17:12 +02:00
Stephan Aßmus 8d611f17a7 TextDocumentView: Fixed leak of BMessageRunner. 2015-09-10 21:56:38 +02:00
Stephan Aßmus 81f55cc896 HaikuDepot, text framework: Rework blinking the caret
Make sure that the caret starts blinking half a second after it last moved.
The previous solution using Pulse() had a number of problems:
 * The caret could be hidden during moving it or during typing. It would then
   be shown again very soon after, i.e. when typing the next character or
   when moving it to the next offset. But it looks bad anyway.
 * When the caret stopped moving, it started blinking a random amount of
   time afterwards, getting back into the rhythm of Pulse() messages.
   However, starting to blink a constant time after the caret last moved,
   looks much more satisfying.
2015-09-10 21:56:33 +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
Stephan Aßmus 36ab52c74e HaikuDepot: Adapt package contents when package status changes
Based on a patch in ticket #11886 by TwoFx, but with checks for
packageRef.Get() != NULL and better member name for the package status.
2015-08-20 16:25:07 +02:00
Stephan Aßmus f333ade309 Icon-O-Matic: Converted color picker to use layouting
Basically synced the code with what I did for WIP WonderBrush rewrite.
 * Converted to use layouting
 * Removed unused liblayout MView cruft
 * Removed need for rendering in separate threads in favor of
   rendering lazily. The original Colors! rendering was insanely slow
   and inefficient, hence the separate rendering threads.
 * Some style fixes along the way.
 * Some minor bug fixes, too, but these were not actually triggered.
 * Renamed selected_color_mode.h to SelectedColorMode.h
2015-07-19 23:20:22 +02:00
Stephan Aßmus 0ebc8ac6ef IOM/ColorField: Get rid of useless threads
Generate bitmap in Draw() lazily. Removed liblayout stuff. Support for
Haiku layout methods. Fixed some bugs with selecting red/green/blue
as fixed values (ticket #10574).
2015-07-19 23:20:11 +02:00
Stephan Aßmus 44046ca5cd IOM/AlphaSlider: Removed liblayout suff, added Haiku layout methods
Also added support for border styles.
2015-07-19 23:20:02 +02:00
Stephan Aßmus 0cbb6c11ee Icon-O-Matic: Make GradientTransformable a BReferenceable
* Switch to using support/Referenceable.h instead of using an older copy
   of this code.
 * Make GradientTransformable a BReferenceable and fix #12033.
2015-05-09 21:38:15 +02:00
Stephan Aßmus f67071b98c HaikuDepot: Re-activated Size-column
Noticed that HaikuDepotServer info now contains "payloadLength", which is
the package size. Populate that in the list view.
2015-04-04 22:45:46 +02:00
Stephan Aßmus 53094e2fa1 StringForSize.h: Fixed header guard comment at EOF 2015-04-04 22:45:41 +02:00
Stephan Aßmus 72992391bb HaikuDepot: Title versus Name distinction
* The name is the static package name. The title is either that name,
   or a translated pretty version of the name.
 * Adjust package info retrieval to server API changes. Unbreaks package
   translations.
2015-04-04 22:45:37 +02:00
Stephan Aßmus 4bf45bfb5d HaikuDepot: Added UndoableEditListener list to TextDocument
This is all work in progress. The plan is to move the code that does any
actual changes to the TextDocument into UndoableEdit implementations, then
emit these edits to interesed listeners. They can then store them to
implement the edit history. If there are not listeners, the edits will
simply be released after they've done their work.
Implemented so far is only the support for storing the edit listeners.
2015-02-22 21:25:49 +01:00
Stephan Aßmus b5cbbf8041 HaikuDepot: UndoableEditListener base class added 2015-02-22 21:25:11 +01:00
Stephan Aßmus 651e8326ca HaikuDepot: Base-classes for generic undo/redo support.
I plan to use these in the text view and editor framework.
2015-02-22 20:35:34 +01:00
Stephan Aßmus 7b2c59b9b8 HaikuDepot: Implemented light-weight package manager update
No, not updating packages via HaikuDepot, but a light-weight synchronization
between the system package manager list and the HaikuDepot model. After
installing or removing a package, HaikuDepot performed a very costly update
of all information by basically throwing everything away and reloading it.
Implements #11786.
2015-01-25 22:11:38 +01:00
Stephan Aßmus 4a1fc9b122 HaikuDepot: Keep reference to PackageInfos longer...
... in PackageInfoView::SetPackage() and Clear(). The sub-views reference
stuff from the previous PackageInfo instance. If we release the reference
before adopting the new package, the sub-views may still access stuff from
the previous package. For example the PackageActionView tries to avoid
rebuilding the button list and compares previous package actions to the
new actions. Particularily after the package list has been rebuild, we have
only new PackageInfo instances and the PackageInfoView may hold on to a
PackageInfo that is not still referenced anywhere else. Would be a good
explanation for #11785.
2015-01-25 10:04:23 +01:00
Stephan Aßmus 57e51fff75 HaikuDepot: Fix failing to show some packages after refreshing.
Since the package information is refreshed asynchronously, some packages
may fit the current filter parameters. Check for this situation more
generically in the MSG_PACKAGE_CHANGED notification. Before, it was only
done for prominent packages to make them appear in the Featured packages
view. The problem was visible by for example selecting a category and then
refreshing packages. Many of the previously shown packages would be missing
and magically appear when changing filter parameters slightly and back
to what they were.
2015-01-11 17:22:17 +01:00
Stephan Aßmus 1b5e65f587 HaikuDepot: Adopt selected Depot/Category...
... in FilterView::AdoptModel(). Otherwise the selection is reset
after refreshing packages from the Tools menu. Fixes #10990.
2015-01-11 17:21:19 +01:00
Stephan Aßmus 15eb4c43c9 HaikuDepot: Added RemovePackage() method...
... to PackagedListView.
2015-01-11 17:21:00 +01:00
Stephan Aßmus 18b941b46c HaikuDepot: Added RemovePackage() method...
... to FeaturedPackagesView.
2015-01-11 17:20:22 +01:00
Stephan Aßmus fed7859a71 HaikuDepot: Quitting while contents were populated dead-locked.
Fixes #11737
2015-01-11 16:26:15 +01:00
Stephan Aßmus 2098842047 HaikuDepot: Temporary solution for empty contents tab
Display a message (quick solution: a BStringItem) that package contents are
not available for remote packages.
2015-01-11 00:23:35 +01:00
Stephan Aßmus 788144656e HaikuDepot: Fixed package content extraction
When trying to find a matching parent item, we cannot rely on cached
pointers to BPackageEntries, since those are re-used per entry level
from the BPackageReader. Instead, we build the package entry path as
a string and store that with the list item.

Removed debug output.
2015-01-11 00:12:01 +01:00
Stephan Aßmus 84316965ed HaikuDepot: Populate package contents asynchronously
Also remove debugging output with O(n*n) runtime. The problem for which I
write this is already understood, but it is not yet fixed.
2015-01-10 23:39:27 +01:00
Stephan Aßmus 09f8290534 HaikuDepot: Always init the thread ids...
... also in case creating the semaphores fails.
2015-01-10 23:39:27 +01:00
Stephan Aßmus 05bffa62e6 HaikuDepot: Check thread ids before waiting for threads.
These threads are not created if creating a semaphore failed, so
it's not fixing a bug which anyone has likely encountered.
2015-01-10 23:39:26 +01:00
Stephan Aßmus 9550c5ec8e HaikuDepot: Fixes and cleanup to the Contents tab patch
Most changes were in the PackageContentOutliner and its HandleEntry() method
to make it work correctly. The parent entry of a visited entry may not be
the last parent entry, but some other previously added entry. We need a
PackageEntryItem class to also store the BPackageEntry together with the
list item.
Other small fixes.
2015-01-09 23:07:20 +01:00
Stephan Aßmus 2afa3f3b8b HaikuDepot: Improved screen shot window
* Black background
 * Auto-resize to fit new screen shot, re-center on screen
2015-01-03 22:07:31 +01:00
Stephan Aßmus 9c3e96bfb7 HaikuDepot: Keep same tab when updating package info 2014-12-29 00:04:46 +01:00
Stephan Aßmus 89e4ba17d0 HaikuDepot: Update package info after rating package
Let Model::PopulatePackage() have a mode where it forces the update on a
package that has already been populated. Trigger populating from success
code path in RatePackageWindow. Fixes #11638.
2014-12-28 23:51:23 +01:00
Stephan Aßmus 056d423c39 HaikuDepot: Mark installed featured packages...
... with a checkmark icon.
2014-12-28 23:35:42 +01:00
Stephan Aßmus ee13e7f8dd HaikuDepot: Hide up/down rating votes UI
These are not implemented yet at all.
2014-12-28 22:33:55 +01:00
Stephan Aßmus 7b206268ab HaikuDepot: Hide Size column until it can be implemented
Fixes #10394.
2014-12-28 22:33:54 +01:00
Stephan Aßmus 12107be2ec HaikuDepot: Search all packages when showing featured
The intention was that typing search terms searches all packages, not only
the featured ones. This didn't actually work in Model::CreatePackageList().
2014-12-27 22:25:19 +01:00
Stephan Aßmus 75ba9dbfc3 HaikuDepot: Lock model when selecting a package 2014-12-27 22:25:18 +01:00
Stephan Aßmus 93a7cf94a3 HaikuDepot: Clear package info view if package not listed
If the visible packages list does not contain the currently showing package
anymore after filter parameters have changed, clear the package info area.
This also means that when installed packages are turned off, which means
a package will disappear from the list after being installed, the package
will no longer keep showing in the info area. This situation is less likely
with the change that installed packages will now show by default and the
user has to explicitly turn them off.
2014-12-27 09:38:28 +01:00
Stephan Aßmus 0c6df5d52e HaikuDepot: Fixed regression: selecting featured packages
Since the fVisiblePackages list in MainWindow is now also filtered by
featured packages, and since the "featured" status of packages is collected
asynchronously, the list needs to be updated in the package changed
notification. Also, the package should only be added to the featured packages
view if it is now in the visible list. Other filter criteria would not be
taken into account otherwise. Fixes #11663
2014-12-27 09:38:26 +01:00
Stephan Aßmus 1986ab9f31 HaikuDepot: Sync the selection between normal and featured list 2014-12-26 22:42:11 +01:00
Stephan Aßmus b2843daed7 HaikuDepot: Added PackagesListView::Select(PackageInfo)
which also scrolls the row into view (if it exists).
2014-12-26 22:41:10 +01:00
Stephan Aßmus ede65a8f9b HaikuDepot: Handle NULL PackageInfoRef in FeaturedPackagesView::Select() 2014-12-26 22:40:24 +01:00
Stephan Aßmus 7b434ea483 HaikuDepot: SharedBitmap: Enlarge maximum stream size
This is used for screenshots and some are larger than 128KiB.
2014-12-26 22:38:54 +01:00
Stephan Aßmus 2997e05b4f HaikuDepot: All "Show" settings are persistent now. 2014-12-26 22:20:27 +01:00
Stephan Aßmus 4fade61ff8 HaikuDepot: Change when featured packages are shown
* Renamed the "Option" menu to "Show", removed the now redundant "Show" from
   the items in that menu.
 * Add an "Only featured packages" item in the Show menu. This item is disabled
   as soon as the user types something in the search terms field. Othetwise,
   this setting is respected, i.e. one can combine the featured setting with
   other settings, i.e. show all featured packages of a certain depot and in a
   certain category.
 * Added PackageInfo::IsProminent() and removed the respective method from
   the MainWindow (which only considered a package prominent if it was not
   yet installed).
 * "Show -> Installed packages" now defaults to on. There have been complaints
   on Trac and I guess rightfully so. The use-cases in which one starts
   HaikuDepot and wants to know about installed packages are just as likely
   as the use-case where one wants to install new software.
2014-12-26 22:08:08 +01:00
Stephan Aßmus 474b9e090d HaikuDepot: Check if package_daemon runs and offer to start it
Fixes ticket #9967.
2014-12-23 22:22:06 +01:00
Stephan Aßmus ca747629f9 HaikuDepot: Fix drawing bugs of count view
The packages count view centers its label. It therefore needs a full update
on resize. Also optimize SetItemCount() by trying to avoid unneccessary
layout invalidations.
2014-12-23 14:57:27 +01:00
Stephan Aßmus d5ef985e18 HaikuDepot: Added rudimentary screenshot window.
Clicking the thumbnail in the package info area will now open a
window where the full-size screenshot is downloaded and shown. There can
only be one such screenshot window open. Navigating between multiple
screenshots of a package is not yet implemented. Also, no caching, but
this may be OK as it is, since one usually looks at these only once and
doesn't want the harddrive filling up with screenshots.
2014-11-29 23:07:32 +01:00
Stephan Aßmus f5a8bae677 HaikuDepot: Paragraph: Fixed typo in PrintToStream() 2014-11-29 23:07:30 +01:00
Stephan Aßmus 368ec7fa0e HaikuDepot: Use a LinkedBitmapView for the screenshot. 2014-11-29 23:07:29 +01:00
Stephan Aßmus 77badf8eca HaikuDepot: Added TODO to LinkView and bugfix.
SetViewCursor(NULL) does not unset the view cursor.
2014-11-29 23:07:28 +01:00
Stephan Aßmus a45f75e0c5 HaikuDepot: LinkedBitmapView derived from BitmapView
Sends a BMessage when clicked and enabled, shows the link cursor
when hovered with the mouse.
2014-11-29 23:07:27 +01:00
Stephan Aßmus 8507d262d8 HaikuDepot: Support wheel scrolling in featured packages
* Forward B_MOUSE_WHEEL_CHANGED to parent view from each package row view
 * Configure small/big steps on vertical scroll bar.
2014-11-13 22:58:24 +01:00
Stephan Aßmus 664372ab49 HaikuDepot: Visualize selection in featured packages view 2014-11-09 12:04:50 +01:00
Stephan Aßmus ef40255d5d HaikuDepot: Make summary text non-selectable...
... in the rows of featured packages.
2014-11-09 12:04:48 +01:00
Stephan Aßmus 6e2ac1775e HaikuDepot: Added SetSelectable(bool) to TextDocumentView. 2014-11-09 12:04:47 +01:00
Stephan Aßmus 0a9c902921 HaikuDepot: Show a "Featured packages" label
Also remove the left-over separator in the Tools menu.
2014-11-02 02:00:51 +01:00
Stephan Aßmus 6f6ad9153b HaikuDepot: Improve featured package items
Show the summary instead of the version. The layout still sucks, but I will
have to implement some kind of row/flow BLayout to get what I initially had
in mind. Another TODO is to highlight the clicked item somehow.
2014-11-02 01:38:34 +01:00
Stephan Aßmus dfbf4d3885 HaikuDepot: Fix click detection in featured packages
Take window activation and parent bounds (a featured package scrolled outside
the visible region within the parent) into account.
2014-11-02 01:38:33 +01:00
Stephan Aßmus 1f3c1ef1c5 HaikuDepot: Select clicked featured packages 2014-11-02 01:38:32 +01:00
Stephan Aßmus a3056e412a HaikuDepot: Move selection message constant to MainWindow.h 2014-11-02 01:38:30 +01:00
Stephan Aßmus 419dc642f5 HaikuDepot: Feature packages with prominence <= 200 2014-11-02 01:38:29 +01:00
Stephan Aßmus da6511046d HaikuDepot: Properly add featured packages.
* Rework existing package listener mechanism to report any interesting
   changes. Listen for prominence changes in addition to package state.
 * Add featured packages to the FeaturedPackagesView when their prominence
   is retrived, and also in _AdoptModel().
 * In _AdoptModel(), show the featured packages view when no search filters
   are active and installed packages are not shown either. Otherwise show
   the list of all packages matching the current filtering.
2014-11-02 01:38:28 +01:00
Stephan Aßmus 64458d227c HaikuDepot: Only list featured packages once. 2014-11-02 01:38:27 +01:00
Stephan Aßmus 0c169ace2e HaikuDepot: Add some getters to Model.
For category, depot and search terms filter.
2014-11-02 01:38:25 +01:00
Stephan Aßmus 3d869af5e4 HaikuDepot: Separate MessagePackageListener...
...into MessagePackageListener and OnePackageMessagePackageListener.
The first one doesn't know which package(s) it's listening to. But it
can filter the change notifications now and only react to certain changes.
The second one knows which package it's listening to.
2014-11-02 01:38:24 +01:00
Stephan Aßmus 9f40cd4121 HaikuDepot: Retrieve prominence values from web app 2014-11-02 01:38:23 +01:00
Stephan Aßmus 6072a7e417 HaikuDepot: Added "prominence" member to PackageInfo 2014-11-02 01:38:21 +01:00
Stephan Aßmus 4b930cca9c HaikuDepot: Work in progress on featured packages
Not yet visible. But the package list area in the main window has a card
layout now and a second (hidden) page for featured packages. Which packages
are visible there will depend on the prominence value from the web-app
and other parameters later (suggestions based on packages already installed
and user-ratings). At the moment, there is no mechanism for updating the
package list when package info is retrieved asynchronously, even from the
cache. Also, the view should switch to the list when searching and perhaps
in other situations as well, like selecting a category or when no packages
would be featured. And clicking featured packages does not yet select them in
the info area...
2014-10-26 23:37:18 +01:00
Stephan Aßmus f545fe6acc HaikuDepot: Extracted MarkupTextView into its own files 2014-10-26 23:37:17 +01:00
Stephan Aßmus 7631f91496 HaikuDepot: Beginnings of "featured packages" view
Currently a vertically scrollable container for views which are similar
to the title area in the package info view (and share most code, but it
will diverge later on). Untested and not yet used.
2014-10-26 23:37:15 +01:00
Stephan Aßmus 73a3f44915 HaikuDepot: Extracted MessagePackageListener...
... from PackageInfoView into its own files.
2014-10-26 23:37:14 +01:00
Stephan Aßmus 7d0ce97b27 HaikuDepot: Extraced LinkView and ScrollableGroupView...
... from PackageInfoView.cpp into their own files in ui_generic.
2014-10-26 23:37:13 +01:00
Stephan Aßmus cb9a077fde HaikuDepot: Implemented "opening" installed packages
Package contents are scanned to find deskbar links. If a package has less
than four links, they will be offered in separate "Open <link name>" buttons
in the package info area. Usually, this results in one button to open the
main application from the package. If the heuristic proves to be not good
enough, this could be improved of course.
2014-10-26 23:37:12 +01:00
Stephan Aßmus 2d2824bfff HaikuDepot: Store package file name in PackageInfo
Also removed misplaced WIP functionality to find deskbar links
2014-10-26 23:37:10 +01:00
Stephan Aßmus ad5bc044c5 HaikuDepot: Make sure to pick up changed package action labels 2014-10-26 23:37:09 +01:00