KApplication::cut()....

Benjamin Meyer ben at meyerhome.net
Fri Sep 23 13:06:49 BST 2005


On Thursday 22 September 2005 9:54 am, Simon Hausmann wrote:
> On Thursday 22 September 2005 15:41, Scott Wheeler wrote:
> > On Thursday 22 September 2005 14:40, Benjamin Meyer wrote:
> > > Yah they looked like good ideas and was a little surprised that I
> > > couldn't find anything looking through several of the modules.  What do
> > > you think of moving them to KMainWindow?
> >
> > I'm not really sure that they belong in KMainWindow since they're not
> > window specific.  They're tied to focusWidget() which is a feature of
> > QApplication.
> >
> > Put the other way -- why would you like to see them in KMainWindow?
> >
> > (I also noticed on doing a grep that at least DataKiosk and KTorrent are
> > using these methods as well.)
>
> Maybe we don't need those slots as publically accessible functions at all
> and instead just need to provide methods that do what you already
> pasted as the common way of using them:
>
> 	KStdAction::cut(kapp, SLOT(cut()), actionCollection);
>
> Perhaps something like:
>
> KMainWindow::createAutomaticCutAction(KActionCollection *collection =
> actionCollection())
>
> The slot itself may not be related to the mainwindow, but the action is
> bound to it after all. (strictly speaking only to the actioncollection but
> hey, we're trying to simplify the common case :)
>
> Simon

Attached is a patch to move cut,copy,paste,clear, and selectAll to 
KMainWindow.  Any objections to commiting?

-Benjamin Meyer

-- 
aka icefox
Public Key: http://www.icefox.net/public_key.asc
-------------- next part --------------
A non-text attachment was scrubbed...
Name: diff
Type: text/x-diff
Size: 9865 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20050923/1e16469e/attachment.diff>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20050923/1e16469e/attachment.sig>


More information about the kde-core-devel mailing list