import QtQuick 1.1 import com.meego 1.0 PageStackWindow { id: rootWindow property int pageMargin: 16 platformStyle: defaultStyle; PageStackWindowStyle { id: defaultStyle } PageStackWindowStyle { id: customStyle; background: "image://theme/meegotouch-wallpaper-portrait"} // ListPage is what we see when the app starts, it links to the component specific pages initialPage: MainPage { } // These tools are shared by most sub-pages by assigning the id to a page's tools property ToolBarLayout { id: commonTools visible: false ToolIcon { iconId: "toolbar-back"; onClicked: { myMenu.close(); pageStack.pop(); } } ToolIcon { iconId: "toolbar-view-menu"; onClicked: (myMenu.status == DialogStatus.Closed) ? myMenu.open() : myMenu.close() } } Menu { id: myMenu visualParent: pageStack MenuLayout { MenuItem {id: b1; text: "Landscape"; onClicked: screen.allowedOrientations = Screen.Landscape} MenuItem {id: b2; text: "Portrait"; onClicked: screen.allowedOrientations = Screen.Portrait} MenuItem {id: b3; text: "Item 3"; onClicked: myMenu.accept()} MenuItem {id: b4; text: "Item 4"; onClicked: myMenu.accept()} } } }