Exemplo n.º 1
0
void SheetsPage::openFullscreenPhotoSheet()
{
    fullScreenPhotoSheet = new MSheet;
    fullScreenPhotoSheet->setStyleName("PhotoViewer");

    populateFullscreenPhotoSheetCentralWidget(fullScreenPhotoSheet->centralWidget());
    populateFullscreenPhotoSheetHeader(fullScreenPhotoSheet);

    connect(fullScreenPhotoSheet, SIGNAL(disappearing()), this, SLOT(reparentPhotoImage()));
    fullScreenPhotoSheet->appear(scene(), MSceneWindow::DestroyWhenDone);


    QPropertyAnimation *animation = new QPropertyAnimation(sheetPhoto, "geometry", sheetPhoto);
    animation->setStartValue(sheetPhoto->geometry());
    animation->setEndValue(fullScreenPhotoSheet->centralWidget()->geometry());
    animation->setDuration(350);
    animation->setEasingCurve(QEasingCurve::InOutExpo);
    animation->start();
}
Exemplo n.º 2
0
MainPage::MainPage(QGraphicsItem *parent)
	: MApplicationPage(parent),
	  m_objectMenu(NULL),
	  m_unknownObjectMenu(NULL),
	  m_longTapIndex(QModelIndex())
{
	m_bluez = new BluezSupplicant(this);
	m_reader = new TagReader(this);
	m_monitor = new NfcdMonitor(this);

	connect(this, SIGNAL(appeared()), 
		this, SLOT(pageAppeared()));

	connect(this, SIGNAL(disappearing()), 
		this, SLOT(pageDisappearing()));

	connect(m_reader, SIGNAL(messageRead(const QNdefMessage)),
		this, SLOT(messageRead(const QNdefMessage)));

	m_monitor->start();
}
void ToolBarPage::createContent()
{
    TemplatePage::createContent();

    setupCheckBoxes();
    setupSliders();

    resetButton = new MButton();
    resetButton->setObjectName("resetButton");
    resetButton->setStyleName(inv("CommonSingleButton"));
    connect(resetButton, SIGNAL(clicked()), this, SLOT(reset()));
    containerPolicy->addItem(resetButton, Qt::AlignCenter);

    callList = new MList;
    callList->setObjectName("callList");
    cellCreator = new MContentItemCreator;
    callList->setCellCreator(cellCreator);
    callModel = new TestModel;
    callModel->setObjectName("callModel");
    callList->setItemModel(callModel);
    containerPolicy->addItem(callList);
    showCallDataAsGrid();

    toolsConfiguration();

    toolsAction = new MAction(this);
    toolsAction->setObjectName("toolsAction");
    toolsAction->setLocation(MAction::ApplicationMenuLocation);
    connect(toolsAction, SIGNAL(triggered()), this, SLOT(toolsConfiguration()));
    addAction(toolsAction);

    textButtonsAction = new MAction(this);
    textButtonsAction->setObjectName("textButtonsAction");
    textButtonsAction->setLocation(MAction::ApplicationMenuLocation);
    connect(textButtonsAction, SIGNAL(triggered()), this, SLOT(textButtonsConfiguration()));
    addAction(textButtonsAction);

    textFieldAction = new MAction(this);
    textFieldAction->setObjectName("textFieldAction");
    textFieldAction->setLocation(MAction::ApplicationMenuLocation);
    connect(textFieldAction, SIGNAL(triggered()), this, SLOT(textFieldConfiguration()));
    addAction(textFieldAction);

    iconTabsAction = new MAction(this);
    iconTabsAction->setObjectName("iconTabsAction");
    iconTabsAction->setLocation(MAction::ApplicationMenuLocation);
    connect(iconTabsAction, SIGNAL(triggered()), this, SLOT(iconTabsBottomConfiguration()));
    addAction(iconTabsAction);

    iconAndLabelTabsAction = new MAction(this);
    iconAndLabelTabsAction->setObjectName("iconAndLabelTabsAction");
    iconAndLabelTabsAction->setLocation(MAction::ApplicationMenuLocation);
    connect(iconAndLabelTabsAction, SIGNAL(triggered()), this, SLOT(iconAndLabelTabsBottomConfiguration()));
    addAction(iconAndLabelTabsAction);

    iconTabsTopAction = new MAction(this);
    iconTabsTopAction->setObjectName("iconTabsTopAction");
    iconTabsTopAction->setLocation(MAction::ApplicationMenuLocation);
    connect(iconTabsTopAction, SIGNAL(triggered()), this, SLOT(iconTabsTopConfiguration()));
    addAction(iconTabsTopAction);

    connect(this, SIGNAL(appearing()), this, SLOT(onAppear()));
    connect(this, SIGNAL(disappearing()), this, SLOT(onDisappear()));

    retranslateUi();
}