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

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? i_combo.cpp

?? 嵌入式開發(fā)工具
?? CPP
?? 第 1 頁 / 共 2 頁
字號(hào):
//	Zinc Application Framework - I_COMBO.CPP//  Copyright (c) 1990-1998 Zinc Software, Inc.//  Copyright (c) 1999-2003 Wind River Systems, Inc./*modification history--------------------01q,19jun03,jlb  Fix SPR 71147 - correction of combo box height01p,07may01,wdf  Changed copyright date.01o,21nov00,wdf  Fixed SPR# 36092.  Viewonly combo box is not cleared when                 last item is deleted.01n,23oct00,wdf  Changed copyright date.01m,20oct00,wdf  Fixed crash problem on SH7750.01l,19oct00,bbj  Fix focus problem01k,22sep00,bbj  Fix for view only combo with UGL windowing01j,21jul00,bbj  Switch to using UGL windows01i,06jul00,bbj  reentrancy protection under ZAF_RTOS vs. ZAF_REENTRANT01h,04apr00,jom  Remove redundant editMode code01g,24feb00,wdf  Added code to Event() function to call event listeners.01f,28jan00,wdf  Made changes for drawhook.01e,15oct99,wdf  Fixed problem of combo not showing focus after an item was                 selected.01d,21sep99,bbj  Interop--switch to EventManager(), WindowManager() accessors01c,19aug99,bbj  Add multithread protection01b,10aug99,bbj  Remove unused static members01a,27jul99,wdf  Documented code, removed commented code, unneeded functions                 and #defines*/#include <zinc/generic/i_combo.hpp>#include <zinc/z_app.hpp>#include <zinc/z_ctype.hpp>#define USE_RAW_KEYS#include <zinc/z_keymap.hpp>#include <zinc/z_lang.hpp>#include <zinc/z_mouse2.hpp>#include <zinc/z_string.hpp>#include <zinc/z_utils.hpp>// ----- ZafComboBox ------------------------------------------------------////////////////////////////////////////////////////////////////////////////////// ZafComboBox::Add - Adds object to the combo list.//// This function overloads base ZafList::Add() functionality to// handle advanced addition operations typical of derived ZafWindow classes.// For objects added to ZafWindow, these three operations are performed:// - they are added to the list of support or non-support children (either the //   support member or the base ZafList part of the class, respectively)// - their parent pointer is set to point to the ZafWindow object// - they are updated on the screen if the parent window is already visible //   to the user// // RETURNS: a typesafe ZafWindowObject pointer, which is generally the object // that was passed to the Add() function, but can be null if the object either // currently resides within another window or is an invalid type of Add() // operation.//ZafWindowObject *ZafComboBox::Add(ZafWindowObject *object, ZafWindowObject *position){	// Add the item to the list.	return (list->Add(object, position));}////////////////////////////////////////////////////////////////////////////////// ZafComboBox::ConvertCoordinates - converts the object's coordinates to// a new type.//// This function converts zafRegion using ConvertRegion() with the specified// coordinate type.//void ZafComboBox::ConvertCoordinates(ZafCoordinateType newType){	if (zafRegion.coordinateType != newType)	{		if (maxListHeight != -1)		{			maxListHeight = (int)display->ConvertYValue(maxListHeight,				zafRegion.coordinateType, newType);			listHeight = maxListHeight;		}		else			listHeight = (int)display->ConvertYValue(listHeight,				zafRegion.coordinateType, newType);		if (listWidth != -1)			listWidth = (int)display->ConvertXValue(listWidth,				zafRegion.coordinateType, newType);		ZafWindow::ConvertCoordinates(newType);	}}ZafEventType ZafComboBox::DispatchMouseEvent(const ZafEventStruct &event){	// This object behaves as an atom.	return (ZafWindowObject::DispatchMouseEvent(event));}////////////////////////////////////////////////////////////////////////////////// ZafComboBox::DragDropEvent - handles drag drop events.//// This function is used internally by ZAF as a dispatch function for system// defined drag/drop messages and should not normally be overloaded by the// programmer. These messages include:// - S_DRAG_DEFAULT// - S_DRAG_MOVE// - S_DRAG_COPY// - S_DRAG_LINK// - S_DROP_DEFAULT// - S_DROP_COPY// - S_DROP_MOVE// - S_DROP_LINK// - S_BEGIN_DRAG// - S_END_DRAG// Whenever an object receives a drag/drop sequence of messages, the messages// are first intercepted in the object抯 Event() function. To allow for more// encapsulation and a more efficient handling of similar drag/drop// functionality, ZAF defines DragDropEvent() which may be called by the base// ZafWindowObject class whenever one of the aforementioned messages is// generated.//// The programmer should not call DragDropEvent(), but it is used internally // by ZAF. When deriving to intercept drag/drop events, the programmer should// always use the Event() function itself.//// RETURNS: event.type if processing is successful. Otherwise, S_ERROR or // S_UNKNOWN may be returned, indicating the object either detected an error // on the message, or that the function did not recognize the specified // message.//ZafEventType ZafComboBox::DragDropEvent(const ZafEventStruct &event){	ZafEventType ccode = event.type;	switch (ccode)	{	case S_BEGIN_DRAG:		if (list->Current())			list->Current()->SetSelected(true);		ZafWindowObject::DragDropEvent(event);		break;	case S_DROP_DEFAULT:		ccode = S_DROP_MOVE;		// Fall through to S_DROP_MOVE.	case S_DROP_COPY:	case S_DROP_MOVE:		if (Disabled() || !AcceptDrop() || WindowManager()->dragObject == this)			return (S_ERROR);		else if (WindowManager()->dragObject->IsA(ID_ZAF_LIST))		{			// Move the selected objects.			ZafWindow *dragList = DynamicPtrCast(WindowManager()->dragObject, ZafWindow);			ZafWindowObject *object;			if (dragList->IsA(ID_ZAF_COMBO_BOX))				object = DynamicPtrCast(dragList, ZafComboBox)->First();			else				object = dragList->First();			while (object)			{				ZafWindowObject *temp = object->Next();				if (object->Selected())				{					if (ccode == S_DROP_COPY)					{						ZafWindowObject *newObject = object->Duplicate();						newObject->SetSelected(false);						Add(newObject);					}					else					{						dragList->Subtract(object);						object->SetSelected(false);						Add(object);					}				}				object = temp;			}		}		else if (OSDraw() && !ViewOnly())			ccode = ZafWindowObject::DragDropEvent(event);		else			ccode = S_ERROR;		break;	default:		ccode = ZafWindow::DragDropEvent(event);		break;	}	return (ccode);}////////////////////////////////////////////////////////////////////////////////// ZafComboBox::Draw - Draws the combobox object.//// Draw() is called whenever the system needs the object to update part, // or all of its information to the screen.//// RETURNS: Draw() returns S_ERROR if some error occurs; otherwise it // returns ccode.//#if defined(ZAF_DEFAULT_DRAW)ZafEventType ZafComboBox::ClassDraw(const ZafEventStruct &event, ZafEventType ccode){	ZafWindow::ClassDraw(event, ccode);	return (ccode);}ZafEventType ZafComboBox::DrawFocus(ZafRegionStruct &, ZafEventType ccode){	return (ccode);}#endif////////////////////////////////////////////////////////////////////////////////// ZafComboBox::Event - Processes events for the combo box object.//// This function provides the core connection between event driven // environment specific architectures and the object-oriented architecture // supported by ZAF. This function receives four general types of events:// - ZAF system events represented by S_* messages.// - ZAF notification events represented by N_* messages.// - ZAF logical interpreted events represented by L_* messages.// - Environment specific events where event.type is E_OSEVENT and the //   environment// specific message is specified by event.osEvent.//// Some types of events are dispatched to other functions. These functions // are DragDropEvent(), MoveEvent(), and ScrollEvent(). The programmer should// not call these specialized functions, but they are used internally by ZAF. // When deriving to intercept events, the programmer should always use the // Event() function itself.//// Events that are tagged with "event.type == E_OSEVENT" are dispatched// directly to the underlying operating environment.//// Events not handled by this function may be passed to the base class's // Evnet() function to be handled.//// RETURNS: The event, S_ERROR, or S_UNKNOWN message.// ZafEventType ZafComboBox::Event(const ZafEventStruct &event){	ZafEventType ccode = LogicalEvent(event);	// Initialize the autoListener.  This will call any preprocessing listeners providing     // listenerStackCount = 1. When it is destroyed any postprocessing listeners will be    // called if the listenerStackCount = 1.    ZafAutoListener autoListener(this, event, ccode);    // If an event listener processed the event and the library should do nothing with it return.    if (event.processed)        return (ccode);	// Check for zinc events.	switch (ccode)	{	// ----- Create messages -----	case S_INITIALIZE:		if (!comboButton)		{			comboButton = new ZafComboButton;			ZafWindow::Add(comboButton);            comboButton->Event(event);		}		comboButton->SetSystemObject(SystemObject());		if (!comboString && (OSDraw() && !viewOnly))		{			comboString = new ZafComboString;			ZafWindow::Add(comboString);                  comboString->Event(event);		}		if ((viewOnly || !OSDraw()) && comboString)		{			ZafWindow::Subtract(comboString);			delete comboString;			comboString = ZAF_NULLP(ZafWindowObject);		}		if (comboString && list->current)			comboString->SetText(list->Current()->Text());		list->Event(event);		ccode = ZafWindow::Event(event);		break;	case L_VIEW:	case L_CONTINUE_SELECT:	case L_END_SELECT:		if (Draggable() && ccode != L_VIEW && !WindowManager()->dragObject)			ZafWindowObject::Event(event);		if (WindowManager()->dragObject)			ZafWindowObject::Event(event);		else		{			ZafPositionStruct mousePosition = event.position;			ZafRegionStruct windowClient = ClientRegion();			if (windowClient.Overlap(mousePosition))			{				// If the mouse is over the client region, convert to the client				// region's coordinates.				mousePosition.column -= windowClient.left;				mousePosition.line -= windowClient.top;				// Cast away the constness so we can have event.position relative				// to the client region.				((ZafEventStruct &)event).position = mousePosition;				// The combo string is the only possible client object.				ZafWindowObject *object = ComboFirst();				if (object && object->Visible() && object->zafRegion.Overlap(mousePosition))				{					// If the string is being overlapped for the first time					// let it set the mouse cursor without making it the					// window manager's mouseObject (that would mess up					// help tips if the combo box had one).					if (ccode == L_VIEW && mouseObject != object)					{						ZafEventStruct mouseEvent = event;						mouseEvent.type = N_MOUSE_ENTER;						object->Event(mouseEvent);						mouseObject = object;					}					else						ccode = object->Event(event);				}			}			else if (comboButton->zafRegion.Overlap(mousePosition))			{				// If the button is being overlapped for the first time				// let it set the mouse cursor without making it the				// window manager's mouseObject (that would mess up				// help tips if the combo box had one).		 		if (ccode == L_VIEW && mouseObject != comboButton)				{					ZafEventStruct mouseEvent = event;					mouseEvent.type = N_MOUSE_ENTER;					comboButton->Event(mouseEvent);					mouseObject = comboButton;				}				else					ccode = comboButton->Event(event);			}			else			{				// If nothing is overlapped, reset the mouse cursor.				if (ccode == L_VIEW)				{					mouseObject = ZAF_NULLP(ZafWindowObject);					EventManager()->SetDeviceState(E_MOUSE, DM_VIEW);				}				else					ccode = ZafWindow::Event(event);			}		}		break;	case L_BEGIN_SELECT:		if (Draggable())			ZafWindow::Event(event);        // Open the drop-down list if a click occurs anywhere on the combo-box.		if (!viewOnly && OSDraw())		{			ZafPositionStruct mousePosition = event.position;			ZafRegionStruct windowClient = ClientRegion();			if (windowClient.Overlap(mousePosition))			{				// If the mouse is over the client region, convert to the client				// region's coordinates.				mousePosition.column -= windowClient.left;				mousePosition.line -= windowClient.top;				// Cast away the constness so we can have event.position relative				// to the client region.				((ZafEventStruct &)event).position = mousePosition;				// The combo string is the only possible client object.				ZafWindowObject *object = ComboFirst();				if (object && object->Visible() && object->zafRegion.Overlap(mousePosition))					return (object->Event(event));			}			else if (comboButton->zafRegion.Overlap(mousePosition))				return (comboButton->Event(event));			else				return (ZafWindow::Event(event));		}		// Continue to L_SELECT.	case L_SELECT:		{			if (ccode == L_SELECT && event.type == E_KEY)			{				if (WindowManager()->First() != list && event.rawCode != F4)				{					(this->*memberUserFunction)(event, L_SELECT);					break;				}			}			if (WindowManager()->First() == list)			{				WindowManager()->Event(S_CLOSE_TEMPORARY);				Event(N_CLOSE_COMBO_LIST);				break;			}			// Put up drop-down list.            int height;			if (!list->First())				height = listHeight;			else			{				// Make sure the item has a valid height.				list->Event(N_SIZE);				listHeight = list->Count() * list->First()->zafRegion.Height() + 2*display->preSpace;				height = ZafMin(listHeight, maxListHeight);			}			int width;			if (listWidth == -1)				width = zafRegion.Width();			else				width = listWidth;			ZafPositionStruct origin;			origin.column = zafRegion.left;			origin.line = zafRegion.bottom;			origin.coordinateType = zafRegion.coordinateType;			origin = parent->ConvertToOSPosition(this, &origin);                        ZafRegionStruct listRegion;            listRegion.Assign(origin.column, origin.line, width, height, origin.coordinateType);            list->SetRegion(listRegion);			if (list->zafRegion.bottom > Display()->lines - 1)				list->zafRegion.VtShift(-(list->zafRegion.Height() +					zafRegion.Height()));			list->SetModal(false);			ZafWindow *scrollBar = DynamicPtrCast(list->SupportFirst(), ZafWindow);			if (scrollBar)				scrollBar->SetTemporary(false);			list->overlapped = false;			WindowManager()->Add(list);			list->Event(S_VSCROLL_CHECK);			Event(N_OPEN_COMBO_LIST);		}		break;	case N_CLOSE_COMBO_LIST:		if (comboString)		    comboString->Event(S_CURRENT);		break;	case N_MOUSE_ENTER:		ZafWindow::Event(event);		mouseObject = ZAF_NULLP(ZafWindowObject);		break;	case S_NON_CURRENT:	case S_CURRENT:		{			bool _focus = focus;			current = comboString;			ZafWindow::Event(event);			if (ccode == S_CURRENT && focus && comboString)				comboString->SetFocus(true);			else if (ccode == S_NON_CURRENT && !focus && comboString)				comboString->SetFocus(false);			if (_focus != focus)				Redisplay();		}		break;	case L_UP:	case L_DOWN:		list->Event(event);		break;	case L_NEXT:	case L_PREVIOUS:		ccode = S_UNKNOWN;		break;	case E_KEY:		if (comboString)			comboString->Event(event);		MatchInput(event.key.value);		break;

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
日韩欧美综合在线| 久久久99精品免费观看不卡| 国产在线精品一区二区不卡了| 国产欧美综合在线观看第十页| 色综合久久99| 国内精品在线播放| 亚洲国产欧美日韩另类综合 | 丁香激情综合五月| 亚洲午夜精品17c| 欧美经典三级视频一区二区三区| 欧美日韩一区二区在线视频| 高清在线观看日韩| 久久精品噜噜噜成人88aⅴ| 亚洲视频每日更新| 久久先锋影音av鲁色资源| 欧美日韩电影一区| 色又黄又爽网站www久久| 国产一区二区美女| 日韩精品福利网| 亚洲精品福利视频网站| 国产欧美日韩亚州综合| 日韩女优毛片在线| 91精品国模一区二区三区| 日本韩国精品一区二区在线观看| 大白屁股一区二区视频| 黄页视频在线91| 蜜臀av性久久久久蜜臀av麻豆| 国产白丝精品91爽爽久久 | 极品少妇一区二区| 日韩av电影免费观看高清完整版 | 99亚偷拍自图区亚洲| 寂寞少妇一区二区三区| 日本大胆欧美人术艺术动态| 亚洲午夜在线视频| 亚洲精品国产无套在线观| 中日韩av电影| 国产欧美精品一区二区色综合| www激情久久| 日韩精品在线一区二区| 91精品国产乱| 日韩欧美一区在线| 日韩欧美另类在线| 日韩欧美的一区| 欧美成人综合网站| 日韩精品一区在线观看| 欧美成人精品3d动漫h| 91精品国产入口在线| 欧美精品少妇一区二区三区| 欧美久久久久中文字幕| 欧美日韩国产首页| 欧美色精品在线视频| 精品视频一区二区不卡| 亚洲免费色视频| 亚洲少妇30p| 亚洲激情图片qvod| 午夜视频久久久久久| 日本视频在线一区| 久久99精品网久久| 国产福利不卡视频| 99视频一区二区三区| 色妹子一区二区| 欧美午夜寂寞影院| 日韩精品一区二区三区三区免费| 精品国产一区二区三区不卡| 久久婷婷国产综合精品青草| 国产精品乱人伦一区二区| 亚洲欧美日韩国产中文在线| 五月天国产精品| 国产一区福利在线| 99久久99久久综合| 欧美另类一区二区三区| 久久午夜电影网| 日韩伦理免费电影| 美女一区二区久久| 成人短视频下载| 欧美午夜精品久久久| 精品久久人人做人人爽| 国产精品久久久久久久久久久免费看 | 欧美一区三区二区| 26uuu亚洲| 亚洲蜜臀av乱码久久精品| 日本麻豆一区二区三区视频| 成人综合日日夜夜| 欧美色图12p| 久久精品一区二区三区av| 亚洲蜜臀av乱码久久精品| 日韩国产成人精品| 成人av在线影院| 制服丝袜亚洲色图| 国产精品日韩成人| 午夜不卡av在线| 懂色av一区二区三区免费观看| 精品视频全国免费看| 国产午夜精品久久久久久久| 亚洲成人动漫精品| 粉嫩av一区二区三区在线播放| 欧美丰满一区二区免费视频| 国产精品嫩草影院com| 日韩av一二三| 91尤物视频在线观看| 精品国产91九色蝌蚪| 亚洲制服欧美中文字幕中文字幕| 激情欧美日韩一区二区| 欧美日韩精品一区二区在线播放| 国产亚洲欧美日韩俺去了| 亚洲成av人片在www色猫咪| 成人aaaa免费全部观看| 精品国产乱码久久| 午夜视频一区二区三区| 色综合久久综合网欧美综合网| 久久在线免费观看| 日韩精品亚洲专区| 色婷婷久久一区二区三区麻豆| 久久久久久久久99精品| 欧洲av在线精品| 久久一区二区三区国产精品| 日韩中文字幕一区二区三区| 色呦呦日韩精品| 国产精品久久精品日日| 国产精品自拍一区| 精品少妇一区二区三区视频免付费 | 岛国一区二区三区| 欧美变态tickling挠脚心| 性做久久久久久| 色婷婷精品大视频在线蜜桃视频| 亚洲国产成人在线| 国产激情一区二区三区四区 | 欧美日韩高清在线| 亚洲人成亚洲人成在线观看图片| 国产69精品久久久久777| 精品国产sm最大网站| 美女精品自拍一二三四| 欧美一区二区久久| 丝袜脚交一区二区| 欧美精选一区二区| 日韩国产精品久久久久久亚洲| 欧美性大战久久| 亚洲国产综合视频在线观看| 欧美中文字幕久久| 亚洲mv大片欧洲mv大片精品| 欧美三级韩国三级日本一级| 亚洲综合色区另类av| 在线观看国产日韩| 亚洲一卡二卡三卡四卡 | 成人免费毛片片v| 欧美国产激情一区二区三区蜜月| 国产成人免费9x9x人网站视频| 久久精品日产第一区二区三区高清版| 国产呦萝稀缺另类资源| 国产欧美一区二区在线观看| 高清不卡在线观看| 中文字幕一区二区三区视频| 91视频观看视频| 亚洲国产视频在线| 7777精品伊人久久久大香线蕉超级流畅 | 欧美剧情片在线观看| 日韩电影在线免费观看| 日韩欧美一级特黄在线播放| 国产一区999| 中文字幕av在线一区二区三区| av中文字幕不卡| 亚洲国产日韩一区二区| 日韩三级电影网址| 成人在线视频一区| 亚洲精品国产无套在线观| 91精品国产综合久久国产大片| 久久99精品久久久久婷婷| 欧美激情资源网| 在线观看中文字幕不卡| 秋霞国产午夜精品免费视频| 久久精品免视看| 色网综合在线观看| 美国毛片一区二区| 国产精品高潮呻吟| 欧美日韩精品免费观看视频| 国产在线一区观看| 亚洲精品免费在线观看| 日韩欧美国产精品一区| 成a人片国产精品| 日韩在线一区二区三区| 中文字幕成人在线观看| 欧美日韩国产精品自在自线| 国产麻豆午夜三级精品| 亚洲v中文字幕| 久久九九国产精品| 欧美日韩精品一区视频| 成人动漫一区二区在线| 欧美a一区二区| 最新日韩av在线| 精品免费国产二区三区| 欧美在线免费观看亚洲| 国产精品一区免费视频| 日韩专区欧美专区| 亚洲男人的天堂在线aⅴ视频 | 久久精品一区蜜桃臀影院| 欧美午夜理伦三级在线观看| 床上的激情91.| 麻豆精品一区二区三区| 亚洲伊人伊色伊影伊综合网| 久久久久亚洲蜜桃|