void CCdlExplorerContainer::OpenL() { CCdlExplorable* selected = CurrentSelected(); if (selected && selected->CanOpen()) { if (!selected->Count()) selected->OpenL(); PushViewL(selected); DrawNow(); } }
void CCdlExplorerContainer::PropertiesL() { CCdlExplorable* selected = CurrentSelected(); if (selected) { TBuf<256> buf; selected->Properties(buf); CAknMessageQueryDialog* dialog = new (ELeave) CAknMessageQueryDialog; dialog->SetMessageTextL(buf); dialog->ExecuteLD(R_PROPERTIES_MESSAGE_QUERY); } }
void CCdlExplorerContainer::HandleListBoxEventL(CEikListBox* /*aListBox*/, TListBoxEvent aEventType) { if (aEventType == EEventEnterKeyPressed) { CCdlExplorable* selected = CurrentSelected(); if (selected) { if (selected->CanOpen()) OpenL(); else PropertiesL(); } } }
void cCustomShotTable::mousePressEvent(QMouseEvent *event) { QTableWidget::mousePressEvent(event); if ((IsDragOn==1)||(columnCount()==0)||(DiaporamaObject==NULL)) return; setCursor(Qt::ArrowCursor); IsDragOn=0; // Get item number under mouse int ThumbWidth =columnWidth(0); int Selected =(event->pos().x()+horizontalOffset())/ThumbWidth; if ((Selected>=0)&&(Selected<NbrItem())) { // if item is correct, check if it was previously selected. Then if not select it if (Selected!=CurrentSelected()) SetCurrentCell(Selected); else { // if it was previously selected then start a drag & drop operation IsDragOn=1; DragItemSource=Selected; DragItemDest =Selected; //RepaintCell(Selected); setCursor(Qt::ClosedHandCursor); } } }
void CCdlExplorerContainer::ApplyLayerL() { CCdlExplorable* selected = CurrentSelected(); if (selected) selected->ApplyLayerL(); }
void CCdlExplorerContainer::ApplyStandAloneL() { CCdlExplorable* selected = CurrentSelected(); if (selected) selected->ApplyStandAloneL(); }
TBool CCdlExplorerContainer::CanBeApplied() { CCdlExplorable* selected = CurrentSelected(); return selected && selected->CanBeApplied(); }