Commit graph

3436 commits

Author SHA1 Message Date
Ivailo Monev
68972d2ddd kdecore: add debug areas for kdirshare and kscreensaver
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-12-01 18:33:42 +02:00
Ivailo Monev
c5cf1cc960 kdecore: remove bogus kmimetype_nomimetypes test
the test is for the worse case scenario, i.e. what if /etc/passwd is
missing? in that case the system is borked and should be fixed, that's
not a problem Katana will (or should) solve nor workaround tho

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-12-01 05:55:34 +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
ce4f5b3c14 plasma: build fix for the case when NDEBUG is not defined
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-30 10:15:50 +02:00
Ivailo Monev
b2ad647dcb kioslave: add assert about the curl_off_t assumption
curl_off_t may be typedef-ed to long on some bizarre system, Katie does not
support such tho

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-30 09:44:12 +02:00
Ivailo Monev
77d4eda777 kio: do not check what plugin to use for items with empty MIME type
such items should not be in the queue for preview even, even items for
remote URLs have something vendor-specific or application/octet-stream as
MIME type. fixes KMimeTypeTrader runtime warning

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-30 09:14:28 +02:00
Ivailo Monev
d359858513 kutils: correct default value for widgetStyle
is keramik v3.x style?

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-30 08:39:37 +02:00
Ivailo Monev
58f6472d45 solid: fix screen power management supressesion
this has been broken since before the fork because message was send with
wrong cookie type

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-30 05:23:12 +02:00
Ivailo Monev
806b06db55 kutils: update org.freedesktop.ScreenSaver interface file used by kidletime
those methods were not implemented and were removed

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-30 04:58:11 +02:00
Ivailo Monev
bdccbb1709 generic: implement hybrid suspend/sleep method
marking as extension because it was not implemented before and the FDO
spec is dead (i.e. not a spec anymore), may or may not work with other
power managers implementing the interface (org.freedesktop.PowerManagement)

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-30 02:14:44 +02:00
Ivailo Monev
c06770a96f kio: remove archive slaves leftovers
they were not using the X-KDE-LocalProtocol property either

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-29 11:30:38 +02:00
Ivailo Monev
1460e60247 kio: remove binary compat bits
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-29 11:29:03 +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
b19a07619d kimgio: correct note in jp2 plugin
color space is exclusive value

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-29 02:46:42 +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
a8ec0ae048 plasma: remove binary compat bits
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-28 01:28:02 +02:00
Ivailo Monev
211ea52f22 kdecore: PCI IDs database update
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-27 23:41:10 +02:00
Ivailo Monev
d598c3cccf kimgio: verify the image color space earlier in jp2 plugin
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-27 18:23:35 +02:00
Ivailo Monev
a0afe27554 kimgio: do not attempt to load images in YUV, e-YCC and CMYK color space
if the decoder cannot tell (correctly) the color space then.. idk

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-27 18:17:19 +02:00
Ivailo Monev
ac32164782 kdeui: remove unused KFontChooser widget
unused since the raw (X11) fonts support was dropped

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-27 07:29:50 +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
6e8e2238cc kdecore: add comment to KDebug() default switch case
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-27 04:51:47 +02:00
Ivailo Monev
f80529f5cd kdecore: replace hard-codec KDebug output types with enums
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-27 02:44:44 +02:00
Ivailo Monev
945f411733 kparts: disconnect the slotWidgetDestroyed() slot from KParts::Part::setAutoDeleteWidget() conditionally
fixes possible crash

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-27 01:46:17 +02:00
Ivailo Monev
1ecd860cd3 kio: specialize only the globs matching
the soft MIME matching via KMimeType::is() is way too.. soft. it can match
application/x-dvi as plain/text (and use ps thumbnailer) which is not ideal
(should use only textthumbnail thumbnailer for plain/text and ps
thumbnailer for application/x-dvi)

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-27 00:02:56 +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
98f1b0b90a plasma: fix shortcuts
who tought using the same shortcut for multiple actions is going to work?
the single character shortcuts are very likely to conflict with other
shortcuts aswell

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-26 11:47:09 +02:00
Ivailo Monev
f9b87a7adf kio: update comment in PreviewJobPrivate::getOrCreateThumbnail()
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-26 06:13:29 +02:00
Ivailo Monev
e3f470feab kio: typo
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-26 06:12:13 +02:00
Ivailo Monev
9e3f2b3eb2 kio: log PreviewJob messages to the kio (KIOJob) debug area
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-26 06:10:02 +02:00
Ivailo Monev
9e5c94b905 kio: check if any of the preferred services is in the list of enabled plugins
the reason for checking the preffered offers first should be obvious - it
is questionable which match should be done first. should it be the glob or
the exact match? chicken and egg thing

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-26 02:25:06 +02:00
Ivailo Monev
bc10416911 kio: try to find thumbnailer plugin via KMimeTypeTrader::query() first
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-26 02:13:58 +02:00
Ivailo Monev
2e6f3fba02 kio: PreviewJobPrivate::startPreview() rewrite
mostly to make the MIME types check consistent by using KMimeType::is()
for the comparison (as done by KPreviewPropsPlugin::supports() for example)
and to filter the ThumbCreator service type (to avoid invalid KMimeType
checks)

fixed KFileMetaInfo regression for plugins that use globs aswell

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-26 01:25:33 +02:00
Ivailo Monev
27de045733 kio: drop unused remote thumbnailers feature
none of the plugins support it and it slows down the thumbnail
preview generation (or fetching of existing thumbnail)

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-25 23:25:40 +02:00
Ivailo Monev
de3384ee46 kio: format and indent previewjob source file
side note: the MIME matching code in PreviewJobPrivate::startPreview() is
spaghetti

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-25 22:41:13 +02:00
Ivailo Monev
86082941ab kded: load service modules in defined order
previously autoloaded modules would be loaded in arbitrary order regardless
of what phase they are ment for from Kded::initModules() but phase two
should be done by ksmserver

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-25 20:51:10 +02:00
Ivailo Monev
b6d30b98fb kded: update examples in HOWTO
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-25 20:10:39 +02:00
Ivailo Monev
bab2e1b6e4 kded: log the kde_running variable value
if it is false then modules that are not ment for full session are not
automatically loaded on init so it shall serve as a hint when debugging

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-11-25 20:01:24 +02:00