History log of /haiku/src/apps/mediaplayer/playlist/RemovePLItemsCommand.cpp
Revision Date Author Comments
# 1cfb79d7 27-Dec-2020 Jaidyn Ann <jadedctrl@teknik.io>

MediaPlayer: Fix playlist manipulation on x86_64

Fixes a problem on x86_64 with removing, shuffling, and moving
multiple playlist items.

Instead of casting directly between an array of addr_t and int32
values, an int32 array is filled manually. Commands are passed
BLists instead of int32 arrays.

Fixes #15737 #16698

Change-Id: I5f67cd511ba10b16bd52d87cda380dd15ce7ee67
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3553
Reviewed-by: waddlesplash <waddlesplash@gmail.com>


# aed35104 05-Aug-2012 Humdinger <humdingerb@gmail.com>

Close alerts with ESCAPE key.

Added SetFlags(B_CLOSE_ON_ESCAPE) or SetShortcut(index, B_ESCAPE) to BAlerts
depending if the result gets used later in the code, or if it's a one-button
BAlert.


# 546208a5 16-Apr-2012 Oliver Tappe <zooey@hirschkaefer.de>

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.


# a5a013ca 07-Jan-2012 Philippe Saint-Pierre <stpere@gmail.com>

MediaPlayer: Fix movement of items in playlist

In Playlist, whenever a move of items occured causing the
currently playing song to change its position, so :
1. Importing files (D&D for example) before its position
2. Removings files before it
3. Moving files before it

was causing the currently playing song to restart because
it was thinking a new entry was asked (it had a different
index number suddently).

Also adjusted the behaviour when you delete the currently
playing track.

Should fix ticket #6689.


# 238df8fb 29-Dec-2010 Adrien Destugues <pulkomandy@pulkomandy.ath.cx>

Patch by Dziadek as part of GCI : localize MediaPlayer.


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


# 7974d3dc 13-Jan-2010 Stephan Aßmus <superstippi@gmx.de>

Patch by Humdinger:
Updated Haiku apps to use sentence-case. What a huge undertaking...
The files where I had to apply the patch manually (for mysterious
reasons) have also gotten a whitespace cleanup. I've proof-read
everything so hopefully there should be no problems.

This should be the final part of #5169.


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


# c60fcc87 23-May-2009 Stephan Aßmus <superstippi@gmx.de>

* Changed the PlaylistItem interface to be hopefully more flexible. It can
probably still be improved.
* Renamed EntryRefPlaylistItem to just FilePlaylistItem.
* Moved the "move into Trash" and "restore from Trash" implementation into
FilePlaylistItem. Also added what's needed to allow Tracker to restore the
entry itself.
* Refactored everything to make Playlist use PlaylistItems instead of
entry_refs and all that entails...
* The transition to virtualize PlaylistItems is not complete yet in the
Controller, since it still uses BMediaFile there. But it's much easier to
change that now.
* Objects which keep a PlaylistItem around do correct reference counting, but
some commands could be simplified if they were using references as well. It
still should work correctly, though, if I didn't miss anything. It should also
fix theoretical situations of encountering out-of-memory while messing with
the Playlist leading to inconsistent state between Undo/Redo and then leaking
items because of that.
* Added the discussed change that MediaPlayer checks it's own supported types
before rejecting a file by super type. (untested)
* When importing playlist items, the currently playling item is better
maintained during Undo/Redo.
* Some debugging code added in MediaTrackAudioSupplier, no functional changes.
* Fixed a number of coding style issues and automatic whitespace cleanup.



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


# bae0154c 16-May-2009 Stephan Aßmus <superstippi@gmx.de>

* I didn't like so much how the "Remove and Move into Trash" feature was
implemented. It didn't reuse existing code and didn't integrate well. No
Undo/Redo except via Tracker, but not in the Playlist... some bugs as well
(Remove had same shortcut as Randomize, Didn't maintain current playback item
if last entry was removed)
* I need to reenable the main window short cut though. This is only temporary.


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


# 415ef601 03-Jun-2007 Stephan Aßmus <superstippi@gmx.de>

* probably fixed the build, did I forget some files before?
* implemented full undo/redo for any playlist operations


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


# aed35104852941f0f6f3d1dcc5338b5f337d0a3c 05-Aug-2012 Humdinger <humdingerb@gmail.com>

Close alerts with ESCAPE key.

Added SetFlags(B_CLOSE_ON_ESCAPE) or SetShortcut(index, B_ESCAPE) to BAlerts
depending if the result gets used later in the code, or if it's a one-button
BAlert.


# 546208a53940a26c6379c48a7854ade1a8250fc5 16-Apr-2012 Oliver Tappe <zooey@hirschkaefer.de>

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.


# a5a013ca40aa991d809cffb85a7367e67132ea0c 07-Jan-2012 Philippe Saint-Pierre <stpere@gmail.com>

MediaPlayer: Fix movement of items in playlist

In Playlist, whenever a move of items occured causing the
currently playing song to change its position, so :
1. Importing files (D&D for example) before its position
2. Removings files before it
3. Moving files before it

was causing the currently playing song to restart because
it was thinking a new entry was asked (it had a different
index number suddently).

Also adjusted the behaviour when you delete the currently
playing track.

Should fix ticket #6689.


# 238df8fb8531e56c1cef834cebe0ad42cb5ed81d 29-Dec-2010 Adrien Destugues <pulkomandy@pulkomandy.ath.cx>

Patch by Dziadek as part of GCI : localize MediaPlayer.


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


# 7974d3dcf39ce78e5885b481eee12e561ad6e096 13-Jan-2010 Stephan Aßmus <superstippi@gmx.de>

Patch by Humdinger:
Updated Haiku apps to use sentence-case. What a huge undertaking...
The files where I had to apply the patch manually (for mysterious
reasons) have also gotten a whitespace cleanup. I've proof-read
everything so hopefully there should be no problems.

This should be the final part of #5169.


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


# c60fcc87e04b0af21ed9f01581b23d1f714a366f 23-May-2009 Stephan Aßmus <superstippi@gmx.de>

* Changed the PlaylistItem interface to be hopefully more flexible. It can
probably still be improved.
* Renamed EntryRefPlaylistItem to just FilePlaylistItem.
* Moved the "move into Trash" and "restore from Trash" implementation into
FilePlaylistItem. Also added what's needed to allow Tracker to restore the
entry itself.
* Refactored everything to make Playlist use PlaylistItems instead of
entry_refs and all that entails...
* The transition to virtualize PlaylistItems is not complete yet in the
Controller, since it still uses BMediaFile there. But it's much easier to
change that now.
* Objects which keep a PlaylistItem around do correct reference counting, but
some commands could be simplified if they were using references as well. It
still should work correctly, though, if I didn't miss anything. It should also
fix theoretical situations of encountering out-of-memory while messing with
the Playlist leading to inconsistent state between Undo/Redo and then leaking
items because of that.
* Added the discussed change that MediaPlayer checks it's own supported types
before rejecting a file by super type. (untested)
* When importing playlist items, the currently playling item is better
maintained during Undo/Redo.
* Some debugging code added in MediaTrackAudioSupplier, no functional changes.
* Fixed a number of coding style issues and automatic whitespace cleanup.



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


# bae0154ca35cc1f8187cf9d09b63e0b08a41ad4f 16-May-2009 Stephan Aßmus <superstippi@gmx.de>

* I didn't like so much how the "Remove and Move into Trash" feature was
implemented. It didn't reuse existing code and didn't integrate well. No
Undo/Redo except via Tracker, but not in the Playlist... some bugs as well
(Remove had same shortcut as Randomize, Didn't maintain current playback item
if last entry was removed)
* I need to reenable the main window short cut though. This is only temporary.


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


# 415ef601dfd3c244a31c1e9d60eb1689da854e3c 03-Jun-2007 Stephan Aßmus <superstippi@gmx.de>

* probably fixed the build, did I forget some files before?
* implemented full undo/redo for any playlist operations


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