D12563: [Run Command] Add closable property so that close button can be disabled.

2018-05-02 Thread Marco Martin
mart added a comment.


  In D12563#257052 , @dscheffer 
wrote:
  
  > In D12563#257024 , @broulik 
wrote:
  >
  > > Urgh. Just because you can doesn't mean you should. This will horribly 
break if the user is running a different look and feel package (different form 
factor, distro branding, etc).
  > >
  > > Please have a look at the "Search" plasmoid in milou which is basically a 
KRunner applet. Perhaps you can improve and/or base your work on that one 
instead.
  >
  >
  > Thanks for pointing that out! I will have a look at milou. But just out of 
curiosity: Will krunner break with other look and feel packages as well? As far 
as I can tell it does the same as I did since I got the idea from there. (see 
lines 93-100 in 
https://github.com/KDE/plasma-workspace/blob/master/krunner/view.cpp)
  
  
  krunner is done to in theory have different uis on different look and feel 
packages.. if the theme wants it.
  right now none of them implement their own krunner, but they can (somewhere 
there is one that implements a kde4 style ui for it iirc)

REPOSITORY
  R120 Plasma Workspace

REVISION DETAIL
  https://phabricator.kde.org/D12563

To: dscheffer, broulik
Cc: mart, plasma-devel, ragreen, Pitel, ZrenBot, lesliezhai, ali-mohamed, 
jensreuterberg, abetts, sebas, apol


D12563: [Run Command] Add closable property so that close button can be disabled.

2018-05-02 Thread Dennis Scheffer
dscheffer added a comment.


  In D12563#257024 , @broulik wrote:
  
  > Urgh. Just because you can doesn't mean you should. This will horribly 
break if the user is running a different look and feel package (different form 
factor, distro branding, etc).
  >
  > Please have a look at the "Search" plasmoid in milou which is basically a 
KRunner applet. Perhaps you can improve and/or base your work on that one 
instead.
  
  
  Thanks for pointing that out! I will have a look at milou. But just out of 
curiosity: Will krunner break with other look and feel packages as well? As far 
as I can tell it does the same as I did since I got the idea from there. (see 
lines 93-100 in 
https://github.com/KDE/plasma-workspace/blob/master/krunner/view.cpp)

REPOSITORY
  R120 Plasma Workspace

REVISION DETAIL
  https://phabricator.kde.org/D12563

To: dscheffer, broulik
Cc: mart, plasma-devel, ragreen, Pitel, ZrenBot, lesliezhai, ali-mohamed, 
jensreuterberg, abetts, sebas, apol


D12563: [Run Command] Add closable property so that close button can be disabled.

2018-05-02 Thread Kai Uwe Broulik
broulik added a comment.


  > wrote a C++ plugin that loads the RunCommand.qml using KPackage and 
subsequently registers the file with the qml type system.
  
  Urgh. Just because you can doesn't mean you should. This will horribly break 
if the user is running a different look and feel package (different form 
factor, distro branding, etc).
  
  Please have a look at the "Search" plasmoid in milou which is basically a 
KRunner applet. Perhaps you can improve and/or base your work on that one 
instead.

REPOSITORY
  R120 Plasma Workspace

REVISION DETAIL
  https://phabricator.kde.org/D12563

To: dscheffer, broulik
Cc: mart, plasma-devel, ragreen, Pitel, ZrenBot, lesliezhai, ali-mohamed, 
jensreuterberg, abetts, sebas, apol


D12563: [Run Command] Add closable property so that close button can be disabled.

2018-05-02 Thread Dennis Scheffer
dscheffer added a comment.


  In D12563#257018 , @mart wrote:
  
  > what's the exact use case? what plasmoid are you writing? (btw, you can't 
use that qml file in a plasmoid, if you want to embed parts of krunner in a 
plasmoids, those are components coming from milou)
  
  
  Thanks for commenting! I'm not exactly sure what you mean by "you can't". It 
works just fine for my use case. I wrote a C++ plugin that loads the 
RunCommand.qml using KPackage and subsequently registers the file with the qml 
type system. It just bothers me that I have a close button in my full 
representation that does nothing. I could just modify a local copy of 
RunCommand.qml (which I did) but I think it would be a cleaner solution to use 
the system wide file in case of future enhancements. Here is a link to my 
project on github: https://github.com/dscheffer/KRunner-Plasmoid

REPOSITORY
  R120 Plasma Workspace

REVISION DETAIL
  https://phabricator.kde.org/D12563

To: dscheffer, broulik
Cc: mart, plasma-devel, ragreen, Pitel, ZrenBot, lesliezhai, ali-mohamed, 
jensreuterberg, abetts, sebas, apol


D12563: [Run Command] Add closable property so that close button can be disabled.

2018-05-02 Thread Marco Martin
mart added a comment.


  what's the exact use case? what plasmoid are you writing? (btw, you can't use 
that qml file in a plasmoid, if you want to embed parts of krunner in a 
plasmoids, those are components coming from milou)

REPOSITORY
  R120 Plasma Workspace

REVISION DETAIL
  https://phabricator.kde.org/D12563

To: dscheffer, broulik
Cc: mart, plasma-devel, ragreen, Pitel, ZrenBot, lesliezhai, ali-mohamed, 
jensreuterberg, abetts, sebas, apol


D12563: [Run Command] Add closable property so that close button can be disabled.

2018-04-27 Thread Dennis Scheffer
dscheffer created this revision.
Restricted Application added a project: Plasma.
Restricted Application added a subscriber: plasma-devel.
dscheffer requested review of this revision.

REVISION SUMMARY
  When using RunCommand.qml, e.g. as part of a plasmoid, it does not always 
make sense to have a close button. This adds a property that makes the element 
configurable in that sense. The closable property's default is 'true' which is 
equivalent to RunCommand's previous behavior. So this change will not break any 
existing software which uses RunCommand.

REPOSITORY
  R120 Plasma Workspace

REVISION DETAIL
  https://phabricator.kde.org/D12563

AFFECTED FILES
  lookandfeel/contents/runcommand/RunCommand.qml

To: dscheffer
Cc: plasma-devel, ragreen, Pitel, ZrenBot, lesliezhai, ali-mohamed, 
jensreuterberg, abetts, sebas, apol, mart