~ubuntu-branches/ubuntu/hardy/smplayer/hardy

« back to all changes in this revision

Viewing changes to src/myaction.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Breuil Cyril
  • Date: 2007-06-24 16:35:29 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20070624163529-hhckbmd24uicada7
Tags: 0.5.20-0ubuntu1
* New upstream release
* Change Maintainer Email

Show diffs side-by-side

added added

removed removed

Lines of Context:
56
56
void MyAction::change(const QString & menuText, const QString & text ) {
57
57
        setMenuText( menuText );
58
58
 
 
59
        QString accel_text = QString(accel());
 
60
 
59
61
        if (text.isEmpty()) {
60
62
                QString s = menuText;
61
 
                setText( s.replace("&","") );
62
 
        } else
 
63
                s = s.replace("&","");
 
64
                setText( s );
 
65
 
 
66
                if (!accel_text.isEmpty())
 
67
                        setToolTip( s + " ("+ accel_text +")");
 
68
        } else {
63
69
                setText( text );
 
70
                if (!accel_text.isEmpty())
 
71
                        setToolTip( text + " ("+ accel_text +")");
 
72
        }
64
73
}
65
74
 
66
75
void MyAction::change(const QString & menuText,