亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? qpopupmenu.cpp

?? qtopia-phone-2.2.0下公共的控件實現源代碼。
?? CPP
?? 第 1 頁 / 共 4 頁
字號:
  several items to a single slot (most often if the user selects from  an array).  This signal is handy in such cases.  \sa activated(), QMenuData::insertItem()*//*! \fn void QPopupMenu::highlightedRedirect( int id )  \internal  Used internally to connect submenus to their parents.*//*! \fn void QPopupMenu::activatedRedirect( int id )  \internal  Used internally to connect submenus to their parents.*/void QPopupMenu::subActivated( int id ){    emit activatedRedirect( id );}void QPopupMenu::subHighlighted( int id ){    emit highlightedRedirect( id );}#ifndef QT_NO_ACCELvoid QPopupMenu::accelActivated( int id ){    QMenuItem *mi = findItem( id );    if ( mi && mi->isEnabled() ) {	actSig( mi->id() );	if ( mi->signal() )	    mi->signal()->activate();    }}void QPopupMenu::accelDestroyed()		// accel about to be deleted{    autoaccel = 0;				// don't delete it twice!}#endif //QT_NO_ACCELvoid QPopupMenu::actSig( int id, bool inwhatsthis ){    bool sync = FALSE;    QPopupMenu * p = this;    while( p && !sync ) {	if ( p == syncMenu )	    sync = TRUE;	else if ( p->parentMenu && p->parentMenu->isPopupMenu )	    p = (QPopupMenu*)(p->parentMenu);	else	    p = 0;    }    if ( sync && qApp ) {	qApp->exit_loop();	syncMenu = 0;    }    if ( !inwhatsthis )	emit activated( id );    else {	QRect r( itemGeometry( indexOf( id ) ) );#ifndef QT_NO_WHATSTHIS	QWhatsThis::leaveWhatsThisMode( findItem( id )->whatsThis(), mapToGlobal( r.bottomLeft() ) );#endif    }    emit activatedRedirect( id );}void QPopupMenu::hilitSig( int id ){    emit highlighted( id );    emit highlightedRedirect( id );}void QPopupMenu::setFirstItemActive(){    QMenuItemListIt it(*mitems);    register QMenuItem *mi;    int ai = 0;    while ( (mi=it.current()) ) {	++it;	if ( !mi->isSeparator() && mi->id() != QMenuData::d->aInt#ifdef QT_KEYPAD_MODE	     && mi->isEnabled()#endif	    ) {	    setActiveItem( ai );	    return;	}	ai++;    }    actItem = -1;}/*!  \internal  Hides all popup menus (in this menu tree) that are currently open.*/void QPopupMenu::hideAllPopups(){    register QMenuData *top = this;		// find top level popup    if ( !preventAnimation )	QTimer::singleShot( 10, this, SLOT(allowAnimation()) );    preventAnimation = TRUE;    if ( !isPopup() )	return; // nothing to do    while ( top->parentMenu && top->parentMenu->isPopupMenu	    && ((QPopupMenu*)top->parentMenu)->isPopup() )	top = top->parentMenu;    ((QPopupMenu*)top)->hide();			// cascade from top level}/*!  \internal  Hides all popup sub-menus.*/void QPopupMenu::hidePopups(){    if ( !preventAnimation )	QTimer::singleShot( 10, this, SLOT(allowAnimation()) );    preventAnimation = TRUE;    QMenuItemListIt it(*mitems);    register QMenuItem *mi;    while ( (mi=it.current()) ) {	++it;	if ( mi->popup() && mi->popup()->parentMenu == this ) //avoid circularity	    mi->popup()->hide();    }    popupActive = -1;				// no active sub menu}/*!  \internal  Sends the event to the menu bar.*/bool QPopupMenu::tryMenuBar( QMouseEvent *e ){    register QMenuData *top = this;		// find top level    while ( top->parentMenu )	top = top->parentMenu;#ifndef QT_NO_MENUBAR    return top->isMenuBar ?	((QMenuBar *)top)->tryMouseEvent( this, e ) :			      ((QPopupMenu*)top)->tryMouseEvent(this, e );#else    return ((QPopupMenu*)top)->tryMouseEvent(this, e );#endif}/*!  \internal*/bool QPopupMenu::tryMouseEvent( QPopupMenu *p, QMouseEvent * e){    if ( p == this )	return FALSE;    QPoint pos = mapFromGlobal( e->globalPos() );    if ( !rect().contains( pos ) )		// outside	return FALSE;    QMouseEvent ee( e->type(), pos, e->globalPos(), e->button(), e->state() );    event( &ee );    return TRUE;}/*!  \internal  Tells the menu bar to go back to idle state.*/void QPopupMenu::byeMenuBar(){    hideAllPopups();#ifndef QT_NO_MENUBAR    register QMenuData *top = this;		// find top level    while ( top->parentMenu )	top = top->parentMenu;    if ( top->isMenuBar )	((QMenuBar *)top)->goodbye();#endif}/*!  \internal  Return the item at \e pos, or -1 if there is no item there, or if  it is a separator item.*/int QPopupMenu::itemAtPos( const QPoint &pos ) const{    if ( !contentsRect().contains(pos) )	return -1;    int row = 0;    int x = contentsRect().x();    int y = contentsRect().y();    int itemw = contentsRect().width() / ncols;    QMenuItem *mi;    QMenuItemListIt it( *mitems );    while ( (mi=it.current()) ) {	++it;	int itemh = itemHeight( row );	if ( ncols > 1 && y + itemh > contentsRect().bottom() ) {	    y = contentsRect().y();	    x +=itemw;	}	if ( QRect( x, y, itemw, itemh ).contains( pos ) )	    break;	y += itemh;	++row;    }    if ( mi && !mi->isSeparator() )	return row;    return -1;}/*!  \internal  Returns the geometry of item number \e index.*/QRect QPopupMenu::itemGeometry( int index ){    QMenuItem *mi;    int row = 0;    int x = contentsRect().x();    int y = contentsRect().y();    int itemw = contentsRect().width() / ncols;    QMenuItemListIt it( *mitems );    while ( (mi=it.current()) ) {	++it;	int itemh = itemHeight( mi );	if ( ncols > 1 && y + itemh > contentsRect().bottom() ) {	    y = contentsRect().y();	    x +=itemw;	}	if ( row == index )	    return QRect( x,y,itemw,itemh );	y += itemh;	++row;    }    return QRect(0,0,0,0);}/*!  \internal  Calculates and sets the size of the popup menu, based on the size  of the items.*/void QPopupMenu::updateSize(){    polish();#ifndef QT_NO_ACCEL    updateAccel( 0 );#endif    int height = 0;    int max_width = 0;    QFontMetrics fm = fontMetrics();    register QMenuItem *mi;    maxPMWidth = 0;    int maxWidgetWidth = 0;    tab = 0;    int arrow_width = style().popupSubmenuIndicatorWidth( fm );    bool hasWidgetItems = FALSE;    for ( QMenuItemListIt it( *mitems ); it.current(); ++it ) {	mi = it.current();	if ( mi->widget() && mi->widget()->parentWidget() != this ) {	    mi->widget()->reparent( this, QPoint(0,0), TRUE );	}	if ( mi->custom() )	    mi->custom()->setFont( font() );	if ( mi->iconSet() != 0)	    maxPMWidth = QMAX( maxPMWidth,			       mi->iconSet()->pixmap( QIconSet::Small, QIconSet::Normal ).width() + 4 );    }    int dh = QApplication::desktop()->height();    ncols = 1;    QMenuItemListIt it2( *mitems );    while( it2.current() )    {	mi = it2.current();	int w = 0;	int itemHeight = QPopupMenu::itemHeight( mi );	bool incr = TRUE;	if ( mi->widget() ) {	    hasWidgetItems = TRUE;	    QSize s( mi->widget()->sizeHint() );	    s.expandedTo( mi->widget()->minimumSize() );	    mi->widget()->resize( s );	    if ( s.width()  > maxWidgetWidth )		maxWidgetWidth = s.width();	    itemHeight = s.height();	} else {	    if ( mi->custom() ) {		if ( mi->custom()->fullSpan() ) {		    maxWidgetWidth = QMAX( maxWidgetWidth, mi->custom()->sizeHint().width() );		} else {		    QSize s ( mi->custom()->sizeHint() );		    w += s.width();		}	    }	    if ( !mi->text().isNull() && !mi->isSeparator() ) {		QString s = mi->text();		int t;		if ( (t=s.find('\t')) >= 0 ) {	// string contains tab		    w += fm.width( s, t );		    w -= s.contains('&')*fm.width('&');		    w += s.contains("&&")*fm.width('&');		    int tw = fm.width( s.mid(t+1) );		    if ( tw > tab)			tab = tw;		} else {		    w += fm.width( s );		    w -= s.contains('&')*fm.width('&');		    w += s.contains("&&")*fm.width('&');		}	    }	}	w += style().extraPopupMenuItemWidth( checkable, maxPMWidth, mi, fm );	if ( mi->popup() ) { // submenu indicator belong in the right tab area	    if ( arrow_width > tab )		tab = arrow_width;	}#if defined(CHECK_NULL)	if ( mi->text().isNull() && !mi->pixmap() && !mi->isSeparator() && !mi->widget() && !mi->custom() )	    qWarning( "QPopupMenu: (%s) Popup has invalid menu item",		     name( "unnamed" ) );#endif	height += itemHeight;	if ( height + 2*frameWidth() >= dh ) 	{	    ncols++;	    height = 0;	    incr = FALSE;	}	if ( w > max_width )	    max_width = w;	if( incr )	    ++it2;    }    if ( tab )	tab -= fontMetrics().minRightBearing();    else	max_width -= fontMetrics().minRightBearing();    if ( max_width + tab < maxWidgetWidth )	max_width = maxWidgetWidth - tab;    if ( ncols == 1 ) {	setFixedSize( max_width + tab + 2*frameWidth(), height + 2*frameWidth() );    }    else {	setFixedSize( (ncols*(max_width + tab)) + 2*frameWidth(), dh );    }    badSize = FALSE;    if ( hasWidgetItems ) {	// Position the widget items. It could be done in drawContents	// but this way we get less flicker.	QMenuItemListIt it(*mitems);	QMenuItem *mi;	int row = 0;	int x = contentsRect().x();	int y = contentsRect().y();	int itemw = contentsRect().width() / ncols;	while ( (mi=it.current()) ) {	    ++it;	    int itemh = itemHeight( row );	    if ( ncols > 1 && y + itemh > contentsRect().bottom() ) {		y = contentsRect().y();		x +=itemw;	    }	    if ( mi->widget() )		mi->widget()->setGeometry( x, y, itemw, mi->widget()->height() );	    y += itemh;	    ++row;	}    }}#ifndef QT_NO_ACCEL/*!  \internal  The \e parent is 0 when it is updated when a menu item has  changed a state, or it is something else if called from the menu bar.*/void QPopupMenu::updateAccel( QWidget *parent ){    QMenuItemListIt it(*mitems);    register QMenuItem *mi;    if ( parent ) {	delete autoaccel;	autoaccel = 0;    } else if ( !autoaccel ) {	// we have no parent. Rather than ignoring any accelerators we try to find this popup's main window	QWidget *w = (QWidget *) this;	parent = w->parentWidget();	while ( (!w->testWFlags(WType_TopLevel) || !w->testWFlags(WType_Popup)) && parent ) {	    w = parent;	    parent = parent->parentWidget();	}    }    if ( parent == 0 && autoaccel == 0 ) 	return;    if ( autoaccel )				// build it from scratch	autoaccel->clear();    else {	// create an autoaccel in any case, even if we might not use	// it immediately. Maybe the user needs it later.	autoaccel = new QAccel( parent, this );	connect( autoaccel, SIGNAL(activated(int)),		 SLOT(accelActivated(int)) );	connect( autoaccel, SIGNAL(destroyed()),		 SLOT(accelDestroyed()) );	if ( accelDisabled )	    autoaccel->setEnabled( FALSE );    }    while ( (mi=it.current()) ) {	++it;	if ( !mi->isEnabled() ) // ### when we have a good solution for the accel vs. focus widget problem, remove that. That is only a workaround	    continue;	int k = mi->key();	if ( k ) {	    int id = autoaccel->insertItem( k, mi->id() );#ifndef QT_NO_WHATSTHIS	    autoaccel->setWhatsThis( id, mi->whatsThis() );#endif	}	if ( !mi->text().isNull() || mi->custom() ) {	    QString s = mi->text();	    int i = s.find('\t');	    if ( k && k != Key_unknown ) {		QString t = QAccel::keyToString( k );		if ( i >= 0 )		    s.replace( i+1, s.length()-i, t );		else {		    s += '\t';		    s += t;		}	    } else if ( !k ) { 		if ( i >= 0 ) 		    s.truncate( i );	    }	    if ( s != mi->text() ) {		mi->setText( s );		badSize = TRUE;	    }	}	if ( mi->popup() && parent ) {		// call recursively	    // reuse	    QPopupMenu* popup = mi->popup();	    if ( !popup->avoid_circularity ) {		popup->avoid_circularity = 1;		if (popup->parentMenu)		    popup->parentMenu->menuDelPopup(popup);		menuInsPopup(popup);		popup->updateAccel( parent );		popup->avoid_circularity = 0;	    }	}    }}/*!  \internal  It would be better to check in the slot.*/void QPopupMenu::enableAccel( bool enable ){    if ( autoaccel )	autoaccel->setEnabled( enable );    else	accelDisabled = TRUE;			// rememeber when updateAccel    QMenuItemListIt it(*mitems);    register QMenuItem *mi;    while ( (mi=it.current()) ) {		// do the same for sub popups	++it;	if ( mi->popup() )			// call recursively	    mi->popup()->enableAccel( enable );    }}#endif/*!\reimp*/void QPopupMenu::setFont( const QFont &font ){    QWidget::setFont( font );    badSize = TRUE;

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
一区二区三区中文在线| 国产精品久线在线观看| 亚洲另类色综合网站| 精品一二线国产| 欧美视频一二三区| 国产精品色婷婷| 国产中文字幕精品| 911精品国产一区二区在线| 中文字幕五月欧美| 国产裸体歌舞团一区二区| 欧美日韩亚洲综合在线| 亚洲三级在线看| 国产一区二区三区免费看| 欧美日韩视频第一区| 中文字幕亚洲一区二区av在线| 精品一区二区国语对白| 3d成人h动漫网站入口| 亚洲一区二区在线播放相泽| av电影一区二区| 国产欧美视频一区二区三区| 极品少妇xxxx精品少妇| 日韩视频永久免费| 天天射综合影视| 欧美亚洲国产bt| 一区二区三国产精华液| 99久久精品免费看| 国产日本欧美一区二区| 国产精品一区二区无线| 久久久久久久久久久99999| 韩国成人精品a∨在线观看| 日韩三级电影网址| 免费成人在线网站| 欧美一级搡bbbb搡bbbb| 日本在线不卡一区| 欧美一区二区三区色| 午夜精品爽啪视频| 欧美日韩成人高清| 日本一区中文字幕| 日韩欧美一卡二卡| 狠狠色狠狠色综合系列| 精品国产三级电影在线观看| 久久国产成人午夜av影院| 欧美大片顶级少妇| 久久99蜜桃精品| 欧美白人最猛性xxxxx69交| 麻豆国产欧美一区二区三区| 精品国产乱码久久久久久闺蜜| 另类小说综合欧美亚洲| 精品av综合导航| 国产福利一区在线观看| 国产欧美日本一区视频| 成人精品国产一区二区4080| 国产精品女上位| 91农村精品一区二区在线| 亚洲精品国产精华液| 欧美主播一区二区三区美女| 亚洲va欧美va国产va天堂影院| 欧美剧情片在线观看| 麻豆极品一区二区三区| 日本一区二区免费在线| 99精品欧美一区二区三区小说| 亚洲另类在线视频| 欧美福利电影网| 国产精品综合在线视频| 国产精品久久久久久久久免费樱桃 | 欧洲精品在线观看| 午夜一区二区三区视频| 欧美一区二区视频观看视频| 精品一区二区三区在线播放| 欧美韩国日本不卡| 色乱码一区二区三区88| 日韩avvvv在线播放| 久久免费午夜影院| 色网综合在线观看| 日本美女一区二区三区| 国产午夜亚洲精品理论片色戒| 成人av动漫网站| 亚洲一二三四在线| 欧美电影免费提供在线观看| 成人动漫一区二区三区| 亚洲一区二区三区三| 精品日韩一区二区三区免费视频| 成人综合婷婷国产精品久久免费| 亚洲欧美一区二区三区极速播放| 欧美精品在线视频| 国产一区二区剧情av在线| 亚洲人一二三区| 日韩一区二区三区四区五区六区| 国产传媒日韩欧美成人| 亚洲一二三区在线观看| 精品久久久久香蕉网| 一道本成人在线| 麻豆精品一二三| 亚洲色图欧洲色图| 亚洲精品在线观看网站| 日本乱人伦一区| 精品在线一区二区三区| 亚洲乱码精品一二三四区日韩在线| 91精品在线一区二区| 成年人午夜久久久| 久久精品噜噜噜成人88aⅴ| 中文字幕在线观看一区| 欧美成人精精品一区二区频| 99久久国产综合色|国产精品| 蜜桃一区二区三区在线观看| 专区另类欧美日韩| 精品国产乱码久久久久久老虎| 色婷婷综合久色| 国产麻豆精品在线| 热久久一区二区| 一区二区三区免费| 国产日韩欧美精品一区| 5月丁香婷婷综合| 91在线观看地址| 国产一区二区三区四 | 久久嫩草精品久久久久| 欧美区一区二区三区| k8久久久一区二区三区| 国内外成人在线| 亚洲国产一区二区视频| 亚洲色图视频免费播放| 国产色产综合色产在线视频| 欧美一区二区福利视频| 欧美少妇bbb| a4yy欧美一区二区三区| 国产激情精品久久久第一区二区 | 亚洲成人你懂的| 亚洲人成网站在线| 国产精品污网站| 久久综合色婷婷| 欧美一区二区三区四区高清| 欧美性猛交xxxxxx富婆| 97se亚洲国产综合在线| 成人午夜激情影院| 精品夜夜嗨av一区二区三区| 日韩和欧美的一区| 亚洲成国产人片在线观看| 亚洲另类在线制服丝袜| 最近日韩中文字幕| 国产精品午夜久久| 国产日韩精品视频一区| www激情久久| 欧美成人性福生活免费看| 欧美乱熟臀69xxxxxx| 欧美吻胸吃奶大尺度电影| 91麻豆文化传媒在线观看| 99视频一区二区| a美女胸又www黄视频久久| 波多野结衣在线一区| 国产丶欧美丶日本不卡视频| 韩国三级在线一区| 精一区二区三区| 精品一区二区三区视频| 久国产精品韩国三级视频| 久久国产精品第一页| 精品一区二区三区欧美| 国产在线国偷精品免费看| 国内外成人在线视频| 国产精品综合一区二区三区| 国产精品一区在线观看乱码| 大白屁股一区二区视频| 波多野结衣在线一区| 91亚洲精华国产精华精华液| 91浏览器打开| 在线中文字幕一区二区| 欧洲人成人精品| 91超碰这里只有精品国产| 欧美一级高清片| 精品国产一区a| 国产欧美综合在线| 亚洲欧美综合网| 一区二区三区四区国产精品| 亚洲一区影音先锋| 秋霞午夜鲁丝一区二区老狼| 国内精品免费**视频| 国产精品一区二区无线| 99精品久久免费看蜜臀剧情介绍| 色婷婷久久久亚洲一区二区三区 | gogo大胆日本视频一区| 色网站国产精品| 欧美日韩亚洲综合一区二区三区| 欧美精品亚洲一区二区在线播放| 日韩一级视频免费观看在线| www国产精品av| 中文字幕一区二区三区乱码在线| 亚洲综合色在线| 日韩二区在线观看| 国产成人精品aa毛片| 色av成人天堂桃色av| 制服丝袜亚洲网站| 精品少妇一区二区三区免费观看| 欧美精品一区男女天堂| 国产精品福利电影一区二区三区四区| 亚洲精品福利视频网站| 日韩成人一区二区三区在线观看| 国产老女人精品毛片久久| 色94色欧美sute亚洲线路一ni| 69堂成人精品免费视频| 国产欧美日韩在线视频| 亚洲国产精品久久久久秋霞影院|