diff options
author | David Boddie <dboddie@trolltech.com> | 2009-05-20 15:35:01 (GMT) |
---|---|---|
committer | David Boddie <dboddie@trolltech.com> | 2009-05-20 15:35:01 (GMT) |
commit | d5fad16bb0810ad2961643b54aef9674224f2509 (patch) | |
tree | 1b9f79ddb6b4d071afdb07a74fae563a18497890 /examples/tutorials/widgets/childwidget | |
parent | efb14d56ef9cd327f6358f626f79e3ee88078600 (diff) | |
download | Qt-d5fad16bb0810ad2961643b54aef9674224f2509.zip Qt-d5fad16bb0810ad2961643b54aef9674224f2509.tar.gz Qt-d5fad16bb0810ad2961643b54aef9674224f2509.tar.bz2 |
Doc: Used QApplication::translate() instead of QObject::tr().
At some point, we may revise this to use plain C strings at first, then
introduce the concept of translations.
Reviewed-by: Trust Me
Diffstat (limited to 'examples/tutorials/widgets/childwidget')
-rw-r--r-- | examples/tutorials/widgets/childwidget/main.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/examples/tutorials/widgets/childwidget/main.cpp b/examples/tutorials/widgets/childwidget/main.cpp index 8674b6e..fd50b1d 100644 --- a/examples/tutorials/widgets/childwidget/main.cpp +++ b/examples/tutorials/widgets/childwidget/main.cpp @@ -47,11 +47,12 @@ int main(int argc, char *argv[]) QApplication app(argc, argv); QWidget window; window.resize(320, 240); - window.setWindowTitle(QObject::tr("Child widget")); + window.setWindowTitle(QApplication::translate("childwidget", "Child widget")); window.show(); //! [create, position and show] - QPushButton *button = new QPushButton(QObject::tr("Press me"), &window); + QPushButton *button = new QPushButton( + QApplication::translate("childwidget", "Press me"), &window); button->move(100, 100); button->show(); //! [create, position and show] |