DockModeClockWindow::DockModeClockWindow(const QPixmap& pixmap, DockModeWindowManager* dm, int zValue) : DockModeWindow (WindowType::Type_DockModeWindow, pixmap) { setFlag (QGraphicsItem::ItemHasNoContents); setBoundingRect (pixmap.width(), pixmap.height()); setName (LOCALIZED("Time")); setAppId ("com.palm.dockmodetime"); QDeclarativeEngine* qmlEngine = WindowServer::instance()->declarativeEngine(); if(qmlEngine) { QDeclarativeContext* context = qmlEngine->rootContext(); Settings* settings = Settings::LunaSettings(); std::string systemMenuQmlPath = settings->lunaQmlUiComponentsPath + "DockModeTime/Clocks.qml"; QUrl url = QUrl::fromLocalFile(systemMenuQmlPath.c_str()); m_qmlNotifMenu = new QDeclarativeComponent(qmlEngine, url, this); if(m_qmlNotifMenu) { m_clockObject = qobject_cast<QGraphicsObject *>(m_qmlNotifMenu->create()); if(m_clockObject) { m_clockObject->setPos (boundingRect().x(), boundingRect().y()); m_clockObject->setParentItem(this); } } } }
DesktopFile::DesktopFile(QString path, QObject *parent) : QObject(parent) { if (path.startsWith("/")) { setPath(path); } else { setAppId(path); } }
::Ice::DispatchStatus com::renren::sixin::account::MiscService::___setAppId(::IceInternal::Incoming& __inS, const ::Ice::Current& __current) { __checkMode(::Ice::Normal, __current.mode); ::IceInternal::BasicStream* __is = __inS.is(); __is->startReadEncaps(); ::Ice::Long userId; ::Ice::Int appId; __is->read(userId); __is->read(appId); __is->endReadEncaps(); ::IceInternal::BasicStream* __os = __inS.os(); ::com::renren::sixin::account::BaseResultPtr __ret = setAppId(userId, appId, __current); __os->write(::Ice::ObjectPtr(::IceInternal::upCast(__ret.get()))); __os->writePendingObjects(); return ::Ice::DispatchOK; }
AlertWebApp::AlertWebApp(const QString& appId, int width, int height, Window::Type type, PIpcChannel *channel) : WindowedWebApp(0, 0, type,channel), m_isPowerdActivityRunning (false) { setAppId(appId); kMinHeight = Settings::LunaSettings()->positiveSpaceBottomPadding; // Set width to a valid value if(width <= 0) m_width = WebAppManager::instance()->currentUiWidth(); else m_width = width; m_height = constraintHeight(height); m_windowWidth = m_width; m_windowHeight = m_height; init(); }