1 /*******************************************************************************
2 * Copyright (c) 2007-2008 INdT.
3 * This program is free software: you can redistribute it and/or modify
4 * it under the terms of the GNU Lesser General Public License as published by
5 * the Free Software Foundation, either version 3 of the License, or
6 * (at your option) any later version.
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU Lesser General Public License for more details.
13 * You should have received a copy of the GNU Lesser General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
19 ============================================================================
23 Description : CPP Hello World
24 ============================================================================
27 #include <glibmm/i18n.h>
33 /* Class constructor */
34 MyWindow::MyWindow() :
35 m_button_helloworld(_("Say Hello"))
37 /* Set the menu for the application */
38 Hildon::Program::get_instance()->set_common_app_menu(m_main);
40 /* Add items to the menu */
41 m_main.append(m_button_helloworld);
44 /* Attach the callback function to signal handler */
45 m_button_helloworld.signal_activate().connect(
46 sigc::mem_fun(*this, &MyWindow::on_menu_helloworld));
48 /* Make all menu widgets visible */
52 /* Class destructor */
57 void MyWindow::on_menu_helloworld()
59 /* Create and show a "Hello World" dialog */
60 Hildon::Note helloworld_note(Hildon::NOTE_TYPE_INFORMATION, _("Hello World!!!"));
61 helloworld_note.run();