[prev in list] [next in list] [prev in thread] [next in thread]
List: amarok-devel
Subject: Re: [Amarok] Always reload the decorator actions.
From: Seb Ruiz <ruiz () kde ! org>
Date: 2010-02-09 23:08:34
Message-ID: 60ebdd0b1002091508n477f1d02q5622dfcf0918ab5a () mail ! gmail ! com
[Download RAW message or body]
On 10 February 2010 07:10, Bart Cerneels <bart.cerneels@kde.org> wrote:
> QList<QAction*>
> CollectionTreeItem::decoratorActions() const
> {
> - if( m_decoratorActionsLoaded )
> - return m_decoratorActions;
> -
> + QList<QAction*> decoratorActions;
> Meta::DecoratorCapability *dc = m_parentCollection->create<Meta::DecoratorCapability>();
> if( dc )
> {
> - m_decoratorActions = dc->decoratorActions();
> + decoratorActions = dc->decoratorActions();
> delete dc;
> }
> -
> - m_decoratorActionsLoaded = true;
> - return m_decoratorActions;
> + return decoratorActions;
> }
I fear that this could be very slow. Having the recreate the actions
on every paint event seems overkill.
--
Seb Ruiz
http://www.sebruiz.net/
http://amarok.kde.org/
_______________________________________________
Amarok-devel mailing list
Amarok-devel@kde.org
https://mail.kde.org/mailman/listinfo/amarok-devel
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic