Bug 343641 - Color Chooser - Close and Maximize buttons in titlebar does not work
Summary: Color Chooser - Close and Maximize buttons in titlebar does not work
Status: RESOLVED FIXED
Alias: None
Product: kwin
Classification: Plasma
Component: decorations (show other bugs)
Version: 5.2.1
Platform: Kubuntu Linux
: NOR normal
Target Milestone: 5
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-02-01 00:50 UTC by André Marcelo Alvarenga
Modified: 2016-03-16 09:15 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
Screenshot (38.42 KB, image/png)
2015-02-01 00:51 UTC, André Marcelo Alvarenga
Details

Note You need to log in before you can comment on or make changes to this bug.
Description André Marcelo Alvarenga 2015-02-01 00:50:36 UTC
Open Color Chooser dialog and click on these buttons.

Reproducible: Always

Steps to Reproduce:
1. Open Desktop Settings;
2. In 'Wallpaper Type:', choose Plain Color;
3. Click on 'Color:' (square with a color) to open Color Chooser dialog.
4. Try close an maximize the dialog.



Using Plasma 5.1.95
Comment 1 André Marcelo Alvarenga 2015-02-01 00:51:47 UTC
Created attachment 90847 [details]
Screenshot
Comment 2 Kai Uwe Broulik 2015-02-01 12:29:21 UTC
I can confirm this issue.
I'm not sure whether this is a bug in the dialog (disabling the close button for no obvious reason) or the decoration (not honoring this request).
Comment 3 Marco Martin 2015-03-12 09:28:31 UTC
it's an issue of either kwin or the breeze deco:
if i try to run kwin 4, close and maximize are not shown
Comment 4 Hugo Pereira Da Costa 2015-03-12 09:38:47 UTC
(In reply to Marco Martin from comment #3)
> it's an issue of either kwin or the breeze deco:
> if i try to run kwin 4, close and maximize are not shown

So you mean: the buttons should _not_ be there (and they are not with kwin@kde4), but they are here with kf5, but do nothing. 
Right ?
Comment 5 Hugo Pereira Da Costa 2015-03-12 09:40:39 UTC
... I cannot reproduce the problem here, but possibly because I run the color chooser from kde4 (which has working close and maximize buttons)

I'd suspect rather an issue with kwin@kf5, since ... well, the decoration is just adding the buttons it is asked to add, provided by kwin. 
Best way to check would be to test with another decoration (aurorae/plastique) ?
Comment 6 André Marcelo Alvarenga 2015-03-13 02:57:43 UTC
(In reply to Hugo Pereira Da Costa from comment #5)
> ... I cannot reproduce the problem here, but possibly because I run the
> color chooser from kde4 (which has working close and maximize buttons)
> 
> I'd suspect rather an issue with kwin@kf5, since ... well, the decoration is
> just adding the buttons it is asked to add, provided by kwin. 
> Best way to check would be to test with another decoration
> (aurorae/plastique) ?

Don't work with Plastik decoration. Not tested with Aurorae.
Comment 7 Hugo Pereira Da Costa 2015-03-13 08:08:43 UTC
aurorae is plastique in fact.
moving to kwin. (will stay cc in case there is anything i can do on the deco side)
Comment 8 Martin Flöser 2015-03-13 09:13:39 UTC
Confirmed: seems to affect all decoration plugins.
Comment 9 Thomas Lübking 2015-03-13 09:15:42 UTC
What's the xprop on the dialog?
Comment 10 Martin Flöser 2015-03-13 09:36:43 UTC
_NET_WM_ALLOWED_ACTIONS(ATOM) = _NET_WM_ACTION_MOVE, _NET_WM_ACTION_MINIMIZE, _NET_WM_ACTION_SHADE, _NET_WM_ACTION_CHANGE_DESKTOP
_KDE_NET_WM_FRAME_STRUT(CARDINAL) = 4, 4, 29, 4
_NET_FRAME_EXTENTS(CARDINAL) = 4, 4, 29, 4
_NET_WM_DESKTOP(CARDINAL) = 0
_KDE_NET_WM_ACTIVITIES(STRING) = "ca497fc9-d5dc-4261-932c-73c366688d31"
WM_STATE(WM_STATE):
                window state: Normal
                icon window: 0x0
_NET_WM_USER_TIME(CARDINAL) = 315580873
_NET_WM_STATE(ATOM) = _NET_WM_STATE_MODAL
WM_TRANSIENT_FOR(WINDOW): window id # 0x2600e2c
_KDE_NET_WM_USER_CREATION_TIME(CARDINAL) = 315580843
XdndAware(ATOM) = BITMAP
_NET_WM_NAME(UTF8_STRING) = "Select Background Color — Plasma"
_MOTIF_WM_HINTS(_MOTIF_WM_HINTS) = 0x7, 0x4, 0xa, 0x1, 0x0
_NET_WM_WINDOW_TYPE(ATOM) = _NET_WM_WINDOW_TYPE_DIALOG, _NET_WM_WINDOW_TYPE_NORMAL
_XEMBED_INFO(_XEMBED_INFO) = 0x0, 0x1
WM_CLIENT_LEADER(WINDOW): window id # 0x2600004
WM_HINTS(WM_HINTS):
                Client accepts input or input focus: True
                Initial state is Normal State.
_NET_WM_PID(CARDINAL) = 31641
_NET_WM_SYNC_REQUEST_COUNTER(CARDINAL) = 39849530
WM_CLASS(STRING) = "plasmashell", "plasmashell"
WM_PROTOCOLS(ATOM): protocols  WM_DELETE_WINDOW, WM_TAKE_FOCUS, _NET_WM_PING, _NET_WM_SYNC_REQUEST
WM_NORMAL_HINTS(WM_SIZE_HINTS):
                user specified location: 2290, 249
                user specified size: 520 by 446
                program specified minimum size: 520 by 446
                program specified maximum size: 520 by 446
                window gravity: Static

(icon removed for readability)
Comment 11 Thomas Lübking 2015-03-13 09:48:03 UTC
_NET_WM_ALLOWED_ACTIONS(ATOM) = _NET_WM_ACTION_MOVE, _NET_WM_ACTION_MINIMIZE,
_NET_WM_ACTION_SHADE, _NET_WM_ACTION_CHANGE_DESKTOP

I'd say that
a) the dialog is broken. Seriously. (No maximize or clone, that looks like gtk+ dialog behavior, but well...)
b) The decorations need to check client()->isCloseable() etc. and act accordingly (disable or hide the buttons).
   I would oppose altering settings()->decorationButtonsLeft() / Right() because the behavior on disabled features differs among "other OSs"

Alternatively the properties in client() are broken.
Comment 12 Hugo Pereira Da Costa 2015-03-22 19:24:33 UTC
Git commit 46b78432e25a124e9b85b007723435700aec047a by Hugo Pereira Da Costa.
Committed on 22/03/2015 at 19:22.
Pushed by hpereiradacosta into branch 'Plasma/5.2'.

set button's visibility depending on the availability of the corresponding feature

M  +35   -1    kdecoration/breezebutton.cpp

http://commits.kde.org/breeze/46b78432e25a124e9b85b007723435700aec047a
Comment 13 Hugo Pereira Da Costa 2015-03-22 19:24:34 UTC
Git commit 99ce485bda67bdfcdbe4e35bd954b25658248558 by Hugo Pereira Da Costa.
Committed on 22/03/2015 at 19:22.
Pushed by hpereiradacosta into branch 'master'.

set button's visibility depending on the availability of the corresponding feature

M  +35   -1    kdecoration/breezebutton.cpp

http://commits.kde.org/breeze/99ce485bda67bdfcdbe4e35bd954b25658248558
Comment 14 Max Schettler 2016-03-16 02:21:00 UTC
Cannot reproduce issue anymore with KWin 5.5.5 on Archlinux.
Comment 15 Thomas Lübking 2016-03-16 09:15:42 UTC
Behavior is correct in Breeze & Aurorae.
New decos may add new bugs, but that's the nature of things.