Ivailo Monev
856b853b89
kutils: de-duplicate KAudioPlayerModule code
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-08-26 20:15:29 +03:00
Ivailo Monev
4a40419a35
kutils: disable copying of KAudioPlayer, KMediaPlayer and KMediaWidget
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-08-26 17:15:38 +03:00
Ivailo Monev
11f6e4b586
kutils: set the ID of the KAudioPlayer from the KDED module
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-08-25 22:08:15 +03:00
Ivailo Monev
6d0274d417
generic: adjust to Katie changes
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-08-06 23:37:03 +03:00
Ivailo Monev
ee0d50c901
generic: purge most manual tests
...
long overdue, have no use for them
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-07-03 07:03:28 +03:00
Ivailo Monev
ed79c859b2
generic: merge KDELibs4ToolsTargets and KDELibs4LibraryTargets
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-06-17 23:57:38 +03:00
Ivailo Monev
5613e5483c
generic: remove redundant build varibles
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-06-17 20:25:52 +03:00
Ivailo Monev
36c910c653
generic: move stuff from KDE4Internal module to KDELibs4Config
...
large-scale changes to the build system, nothing a user sees tho - it is
all under the hood
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-06-17 19:01:40 +03:00
Ivailo Monev
78933232a2
generic: remove build variable used to specify library type
...
only shared builds are supported now
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2023-06-10 23:19:17 +03:00
Ivailo Monev
d5e9d695df
kutils: do not stop the player from KMediaWidget destructor
...
the state is saved before terminating MPV and that may require the player
to be playing (not paused or stopped)
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-12-23 17:46:55 +02:00
Ivailo Monev
d19d80431b
kutils: stop the volume effect from KMediaWidget::setVolume()
...
the effect duration is 3sec but the user may change the volume meanwhile
via the volume widget
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-12-23 17:21:44 +02:00
Ivailo Monev
b8d4eacdfd
kutils: enable the KMediaWidget position slider and play button on loaded() signal
...
the seekable property of MPV is not be valid until load, also a path may be
loaded via KMediaWidget::player()->load()
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-12-16 21:17:47 +02:00
Ivailo Monev
589c3ca009
kutils: change the slider position before load() in KMediaWidget::open()
...
fixes rare runtime warning about seek command failure. the proper thing
to do is close, wait for close to happen, set slider position, load and
continue the event cycle but that's too complicated when buffering is not
expected to happen on seek (i.e. when a file from the hard-disk is
currently loaded)
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-12-14 22:09:23 +02:00
Ivailo Monev
b38a3f8b41
kutils: fake seek to start when re-opening path from KMediaWidget::open()
...
the event for the position update may be in queue and received after
load()
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-12-14 21:46:41 +02:00
Ivailo Monev
06c1b9dda8
kutils: correct disconnection in KAudioPlayerModule::_removeFinished()
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-12-14 19:42:18 +02:00
Ivailo Monev
7ba06852a7
kutils: add TODO for KMediaWidget
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-12-08 13:20:56 +02:00
Ivailo Monev
00d47751c1
kutils: set the position to zero when the player finishes
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-12-08 13:02:01 +02:00
Ivailo Monev
a0254bdc68
kutils: set KMediaWidget position independant of the value
...
now it works as expected when the arrow keys are pressed or when its
position is changed by clicking while having the mouse cursor on either
side of the current position
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-12-06 11:35:07 +02:00
Ivailo Monev
bd2231fdd6
kutils: use only the width as condition for showing the play button text
...
the height does not affect the position slider size
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-12-02 07:11:10 +02:00
Ivailo Monev
eb94c30c11
kutils: const-ify variable in KMediaWidget::dropEvent()
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-12-01 02:53:06 +02:00
Ivailo Monev
d6d17d194c
kutils: use KMessageBox for the drop event error
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-12-01 02:51:54 +02:00
Ivailo Monev
f744763fcd
kutils: update the play button from KMediaWidget::setPlay()
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-29 07:27:07 +02:00
Ivailo Monev
a735d4ee3b
kutils: remove TODO related to KMediaWidget
...
don't have to restore the position from KMediaWidget itself
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-29 07:26:42 +02:00
Ivailo Monev
22755ffef1
kutils: drop the fullscreen option of the media widget
...
that nasty hack was working like a charm tho. oh, well..
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-29 07:08:27 +02:00
Ivailo Monev
8c1a5d300a
kutils: invert the meaning of the KMediaWidget::setPlay() argument
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-29 06:54:53 +02:00
Ivailo Monev
238f9c37bc
kutils: drop the hidden controls option
...
it is very tricky to do it correctly, especially with KMainWindow and the
like doing their thing with menu/status bars
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-29 06:20:37 +02:00
Ivailo Monev
7408c3b692
kutils: de-duplicate KAbstractPlayer code
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-29 06:03:56 +02:00
Ivailo Monev
12a58a3ee0
kutils: media classes debug and warning messages review
...
some of them were wrapped in i18n() macro with the idea to use some of them
in errorString() getter to report MPV initialization failure for example
but I do not think I will implement that (not that there is error(QString)
signal for reporting MPV failure after its initialization)
the debug messages are also quite spammy (because of time-pos property
changing constantly while playing for example), i.e. don't enable them
unless you have good reason for that because multiple media classes
instances can quickly fill your ~/.xsession-errors with lots of messages
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-29 02:22:04 +02:00
Ivailo Monev
7f4e028fb6
kutils: do not observe loadfile property
...
altought it is a command an event it send for it but the property is not
used by the media classes
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-29 02:09:40 +02:00
Ivailo Monev
883db83628
kutils: KMediaPlayer initialization optimization
...
there used to be "vo" option doing the same I believe, anyway it should
speed up initializations by not checks for other contexts (it is to be
rendered into X11 window after all)
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-29 01:15:44 +02:00
Ivailo Monev
254431d75a
kutils: udate comment in KMediaWidget::_updateError()
...
there used to be option to disable the controls (play/pause button,
position slider, etc.)
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-28 23:07:13 +02:00
Ivailo Monev
b0e419b650
kutils: set the horizontal size type of the main KMediaWidgetUI widget to expanding
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-27 06:13:59 +02:00
Ivailo Monev
797ecf1dfc
kutils: show KMediaWidget play button text conditionally
...
this feature is mostly for Dolphin which fits it into a small area and
there really is not enough space for the position slider
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-27 05:59:37 +02:00
Ivailo Monev
e5dbeb8cb4
kutils: correct slot name in KMediaWidget constructor
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-27 04:52:16 +02:00
Ivailo Monev
5d0377b9e6
kutils: rename the internal KMediaWidget UI class
...
so that the uic tool does not generate code that uses variables with
the name of the private KMediaWidget class (KMediaWidgetPrivate)
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-27 00:45:28 +02:00
Ivailo Monev
667c23d743
kutils: delete the player before the UI from KMediaWidget destructor
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-27 00:36:02 +02:00
Ivailo Monev
90928e8320
generic: store package found definitions in config header
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-30 05:41:21 +02:00
Ivailo Monev
388c3a6fa2
kutils: update URL to video in KMediaWidget test
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-16 17:52:12 +03:00
Ivailo Monev
decb354a0d
generic: prepare for Katie changes
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-14 16:16:22 +03:00
Ivailo Monev
f1a580ebaf
kutils: fix build without MPV
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-02 13:37:59 +03:00
Ivailo Monev
675a066c47
kutils: pass references where possible in KMediaWidget
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-09-28 12:03:32 +03:00
Ivailo Monev
1a06d034e0
kutils: warn when the media player option type is invalid
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-09-23 08:03:09 +03:00
Ivailo Monev
2e3f7122b6
generic: prepare for Katie changes
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-06-11 22:55:59 +03:00
Ivailo Monev
c3a97c782a
kutils: initialize all KMediaWidgetPrivate members and set controls timer member to 0 after killing the timer
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-06-09 16:59:17 +03:00
Ivailo Monev
c4a9b9b161
kutils: instantly change the volume when volume QTimeLine object state is not stopped
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-06-09 05:19:11 +03:00
Ivailo Monev
e008c17c9a
kutils: implement option to smooth the volume on load
...
would be great to do it on stop but that would delay e.g. Dolphin close
event if media preview is active. anyway, don't think any other media
player has such feature
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-06-09 03:44:51 +03:00
Ivailo Monev
997a8df465
kutils: use correct type for double properties in media classes property setter
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-06-05 13:37:11 +03:00
Ivailo Monev
30bb40bf9f
kutils: reimplement media classes command sender, option getter and option setter
...
less bits, less CPU cycles wasted
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-06-04 00:02:22 +03:00
Ivailo Monev
4a4c85431e
kdecore: move K_EXPORT_PLUGIN() macro to kpluginfactory header [ci reset]
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-05-31 09:06:11 +03:00
Ivailo Monev
e4c7b66490
kdecore: move K_EXPORT_PLUGIN() macro to kpluginloader header
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-05-30 22:01:35 +03:00