if(MPanel.UpdateFlag & MP_UPDATE_MESSAGE){ 
if(MPanel.UpdateFlag & MP_UPDATE_MESSAGE){ HGDIOBJ hgdiobj = SelectObject(MPanel.hmdc,MPanel.hFontMessage); SetTextColor(MPanel.hmdc,MPanel.FGColor); SetBkColor(MPanel.hmdc,MPanel.BGColor); SetTextAlign(MPanel.hmdc, TA_LEFT | TA_TOP | TA_NOUPDATECP); switch ( MPanelMessageData.curmode ) { case 0: ExtTextOut(MPanel.hmdc,MPanel.rcMessage.left,MPanel.rcMessage.top, ETO_CLIPPED	| ETO_OPAQUE,&(MPanel.rcMessage), MPanelMessageData.buff,strlen(MPanelMessageData.buff),NULL); case 1: ExtTextOut(MPanel.hmdc,MPanel.rcMessage.left,MPanel.rcMessage.top, ETO_CLIPPED	| ETO_OPAQUE,&(MPanel.rcMessage), MPanelMessageData.buff,strlen(MPanelMessageData.buff),NULL);    case 2: ExtTextOut(MPanel.hmdc,MPanel.rcMessage.left,MPanel.rcMessage.top, ETO_CLIPPED	| ETO_OPAQUE,&(MPanel.rcMessage), MPanelMessageData.buff,strlen(MPanelMessageData.buff),NULL); case -1: default: ExtTextOut(MPanel.hmdc,MPanel.rcMessage.left,MPanel.rcMessage.top, ETO_CLIPPED	| ETO_OPAQUE,&(MPanel.rcMessage), MPanelMessageData.buff,strlen(MPanelMessageData.buff),NULL); } if((HGDIOBJ)hgdiobj!=(HGDIOBJ)NULL && (HGDIOBJ)hgdiobj!=(HGDIOBJ)GDI_ERROR) SelectObject(MPanel.hmdc,hgdiobj); InvalidateRect(hPanelWnd, &(MPanel.rcMessage), FALSE); 
void MPanelUpdate(void){	if(!MPanelOK)		return;	if(MPanel.UpdateFlag==MP_UPDATE_NONE)   	return;	gdi_lock(); // gdi_lock	if(MPanel.UpdateFlag & MP_UPDATE_BACKGROUND){		// rbg}bv\t邪͓hԂB		HPEN hPen;      HBRUSH hBrush;//		COLORREF color = MPanel.FGColor;		COLORREF color = MPanel.BGBGColor;		RECT rc = MPanel.rcMe;		HGDIOBJ hgdiobj_hpen, hgdiobj_hbrush;		hPen = CreatePen(PS_SOLID,1,color);		hBrush = CreateSolidBrush(color);		hgdiobj_hpen = SelectObject(MPanel.hmdc, hPen);		hgdiobj_hbrush = SelectObject(MPanel.hmdc, hBrush);		Rectangle(MPanel.hmdc,rc.left,rc.top,rc.right,rc.bottom);		SelectObject(MPanel.hmdc, hgdiobj_hpen);		DeleteObject(hPen);		SelectObject(MPanel.hmdc, hgdiobj_hbrush);		DeleteObject(hBrush);		InvalidateRect(MPanel.hwnd,&rc, FALSE);   }	if(MPanel.UpdateFlag & MP_UPDATE_TITLE){		HGDIOBJ hgdiobj = SelectObject(MPanel.hmdc,MPanel.hFontTitle);		SetTextColor(MPanel.hmdc,MPanel.FGColor);		SetBkColor(MPanel.hmdc,MPanel.BGColor);	//#include "w32g2_c.h"	SetTextAlign(MPanel.hmdc, TA_LEFT | TA_TOP | TA_NOUPDATECP);		ExtTextOut(MPanel.hmdc,MPanel.rcTitle.left,MPanel.rcTitle.top,    		ETO_CLIPPED	| ETO_OPAQUE,&(MPanel.rcTitle),    		MPanel.Title,strlen(MPanel.Title),NULL);		if((HGDIOBJ)hgdiobj!=(HGDIOBJ)NULL && (HGDIOBJ)hgdiobj!=(HGDIOBJ)GDI_ERROR)			SelectObject(MPanel.hmdc,hgdiobj);		InvalidateRect(hPanelWnd, &(MPanel.rcTitle), FALSE);   }	if(MPanel.UpdateFlag & MP_UPDATE_FILE){		HGDIOBJ hgdiobj = SelectObject(MPanel.hmdc,MPanel.hFontFile);		SetTextColor(MPanel.hmdc,MPanel.FGColor);		SetBkColor(MPanel.hmdc,MPanel.BGColor);		SetTextAlign(MPanel.hmdc, TA_LEFT | TA_TOP | TA_NOUPDATECP);		ExtTextOut(MPanel.hmdc,MPanel.rcFile.left,MPanel.rcFile.top,    		ETO_CLIPPED	| ETO_OPAQUE,&(MPanel.rcFile),    		MPanel.File,strlen(MPanel.File),NULL);		if((HGDIOBJ)hgdiobj!=(HGDIOBJ)NULL && (HGDIOBJ)hgdiobj!=(HGDIOBJ)GDI_ERROR)			SelectObject(MPanel.hmdc,hgdiobj);		InvalidateRect(hPanelWnd, &(MPanel.rcFile), FALSE);   }	if(MPanel.UpdateFlag & MP_UPDATE_TIME){		char buffer[256];		HGDIOBJ hgdiobj = SelectObject(MPanel.hmdc,MPanel.hFontTime);   	sprintf(buffer," %02d:%02d:%02d/%02d:%02d:%02d",			MPanel.CurTime_h,MPanel.CurTime_m,MPanel.CurTime_s,    		MPanel.TotalTime_h,MPanel.TotalTime_m,MPanel.TotalTime_s);		SetTextColor(MPanel.hmdc,MPanel.FGColor);		SetBkColor(MPanel.hmdc,MPanel.BGColor);		SetTextAlign(MPanel.hmdc, TA_LEFT | TA_TOP | TA_NOUPDATECP);		ExtTextOut(MPanel.hmdc,MPanel.rcTime.left,MPanel.rcTime.top,    		ETO_CLIPPED	| ETO_OPAQUE,&(MPanel.rcTime),    		buffer,strlen(buffer),NULL);		if((HGDIOBJ)hgdiobj!=(HGDIOBJ)NULL && (HGDIOBJ)hgdiobj!=(HGDIOBJ)GDI_ERROR)			SelectObject(MPanel.hmdc,hgdiobj);		InvalidateRect(hPanelWnd, &(MPanel.rcTime), FALSE);   }	if(MPanel.UpdateFlag & MP_UPDATE_VOICES){		char buffer[256];		HGDIOBJ hgdiobj = SelectObject(MPanel.hmdc,MPanel.hFontVoices);   	sprintf(buffer," %03d/%03d",MPanel.CurVoices,MPanel.MaxVoices);		SetTextColor(MPanel.hmdc,MPanel.FGColor);		SetBkColor(MPanel.hmdc,MPanel.BGColor);		SetTextAlign(MPanel.hmdc, TA_LEFT | TA_TOP | TA_NOUPDATECP);		ExtTextOut(MPanel.hmdc,MPanel.rcVoices.left,MPanel.rcVoices.top,    		ETO_CLIPPED	| ETO_OPAQUE,&(MPanel.rcVoices),    		buffer,strlen(buffer),NULL);		if((HGDIOBJ)hgdiobj!=(HGDIOBJ)NULL && (HGDIOBJ)hgdiobj!=(HGDIOBJ)GDI_ERROR)			SelectObject(MPanel.hmdc,hgdiobj);		InvalidateRect(hPanelWnd, &(MPanel.rcVoices), FALSE);   }	if(MPanel.UpdateFlag & MP_UPDATE_MVOLUME){		char buffer[256];		HGDIOBJ hgdiobj = SelectObject(MPanel.hmdc,MPanel.hFontVoices);   	sprintf(buffer," %03d%%",MPanel.MVolume);		SetTextColor(MPanel.hmdc,MPanel.FGColor);		SetBkColor(MPanel.hmdc,MPanel.BGColor);		SetTextAlign(MPanel.hmdc, TA_LEFT | TA_TOP | TA_NOUPDATECP);		ExtTextOut(MPanel.hmdc,MPanel.rcMVolume.left,MPanel.rcMVolume.top,    		ETO_CLIPPED	| ETO_OPAQUE,&(MPanel.rcMVolume),    		buffer,strlen(buffer),NULL);		if((HGDIOBJ)hgdiobj!=(HGDIOBJ)NULL && (HGDIOBJ)hgdiobj!=(HGDIOBJ)GDI_ERROR)			SelectObject(MPanel.hmdc,hgdiobj);		InvalidateRect(hPanelWnd, &(MPanel.rcMVolume), FALSE);   }	if(MPanel.UpdateFlag & MP_UPDATE_RATE){		char buffer[256];		HGDIOBJ hgdiobj = SelectObject(MPanel.hmdc,MPanel.hFontRate);   	sprintf(buffer," %05dHz",MPanel.Rate);		SetTextColor(MPanel.hmdc,MPanel.FGColor);		SetBkColor(MPanel.hmdc,MPanel.BGColor);		SetTextAlign(MPanel.hmdc, TA_LEFT | TA_TOP | TA_NOUPDATECP);		ExtTextOut(MPanel.hmdc,MPanel.rcRate.left,MPanel.rcRate.top,    		ETO_CLIPPED	| ETO_OPAQUE,&(MPanel.rcRate),    		buffer,strlen(buffer),NULL);		if((HGDIOBJ)hgdiobj!=(HGDIOBJ)NULL && (HGDIOBJ)hgdiobj!=(HGDIOBJ)GDI_ERROR)			SelectObject(MPanel.hmdc,hgdiobj);		InvalidateRect(hPanelWnd, &(MPanel.rcRate), FALSE);   }	if(MPanel.UpdateFlag & MP_UPDATE_PLAYLIST){		char buffer[256];		HGDIOBJ hgdiobj = SelectObject(MPanel.hmdc,MPanel.hFontList);   	sprintf(buffer," %04d/%04d",MPanel.PlaylistNum,MPanel.PlaylistMax);		SetTextColor(MPanel.hmdc,MPanel.FGColor);		SetBkColor(MPanel.hmdc,MPanel.BGColor);		SetTextAlign(MPanel.hmdc, TA_LEFT | TA_TOP | TA_NOUPDATECP);		ExtTextOut(MPanel.hmdc,MPanel.rcList.left,MPanel.rcList.top,    		ETO_CLIPPED	| ETO_OPAQUE,&(MPanel.rcList),    		buffer,strlen(buffer),NULL);		if((HGDIOBJ)hgdiobj!=(HGDIOBJ)NULL && (HGDIOBJ)hgdiobj!=(HGDIOBJ)GDI_ERROR)			SelectObject(MPanel.hmdc,hgdiobj);		InvalidateRect(hPanelWnd, &(MPanel.rcList), FALSE);   }	if(MPanel.UpdateFlag & MP_UPDATE_MISC){		char buffer[256];		HGDIOBJ hgdiobj = SelectObject(MPanel.hmdc,MPanel.hFontMisc);		buffer[0] = '\0';		switch(MPanel.play_system_mode){    	case GM_SYSTEM_MODE:			strcat(buffer,"[GM]");			break;    	case GS_SYSTEM_MODE:			strcat(buffer,"[GS]");			break;    	case XG_SYSTEM_MODE:			strcat(buffer,"[XG]");			break;		default:      case DEFAULT_SYSTEM_MODE:			strcat(buffer,"[--]");			break;		}		switch(MPanel.current_file_info_file_type){		case  IS_SMF_FILE:			strcat(buffer,"[SMF]");			break;		case  IS_MCP_FILE:			strcat(buffer,"[MCP]");			break;		case  IS_RCP_FILE:			strcat(buffer,"[RCP]");			break;		case  IS_R36_FILE:			strcat(buffer,"[R36]");			break;		case  IS_G18_FILE:			strcat(buffer,"[G18]");			break;		case  IS_G36_FILE:			strcat(buffer,"[G36]");			break;		case  IS_SNG_FILE:			strcat(buffer,"[SNG]");			break;		case  IS_MM2_FILE:			strcat(buffer,"[MM2]");			break;		case  IS_MML_FILE:			strcat(buffer,"[MML]");			break;		case  IS_FM_FILE:			strcat(buffer,"[FM ]");			break;		case  IS_FPD_FILE:			strcat(buffer,"[FPD]");			break;		case  IS_MOD_FILE:			strcat(buffer,"[MOD]");			break;		case  IS_669_FILE:			strcat(buffer,"[669]");			break;		case  IS_MTM_FILE:			strcat(buffer,"[MTM]");			break;		case  IS_STM_FILE:			strcat(buffer,"[STM]");			break;		case  IS_S3M_FILE:			strcat(buffer,"[S3M]");			break;		case  IS_ULT_FILE:			strcat(buffer,"[ULT]");			break;		case  IS_XM_FILE:			strcat(buffer,"[XM ]");			break;		case  IS_FAR_FILE:			strcat(buffer,"[FAR]");			break;		case  IS_WOW_FILE:			strcat(buffer,"[WOW]");			break;		case  IS_OKT_FILE:			strcat(buffer,"[OKT]");			break;		case  IS_DMF_FILE:			strcat(buffer,"[DMF]");			break;		case  IS_MED_FILE:			strcat(buffer,"[MED]");			break;		case  IS_IT_FILE:			strcat(buffer,"[IT ]");			break;		case  IS_PTM_FILE:			strcat(buffer,"[PTM]");			break;		default:		case  IS_OTHER_FILE:			strcat(buffer,"[---]");			break;		}		if(MPanel.current_file_info_max_channel>=0){      	char local[16];         sprintf(local,"[%02dch]",MPanel.current_file_info_max_channel+1);			strcat(buffer,local);      }else			strcat(buffer,"[--ch]");		SetTextColor(MPanel.hmdc,MPanel.FGColor);		SetBkColor(MPanel.hmdc,MPanel.BGColor);		SetTextAlign(MPanel.hmdc, TA_LEFT | TA_TOP | TA_NOUPDATECP);		ExtTextOut(MPanel.hmdc,MPanel.rcMisc.left,MPanel.rcMisc.top,    		ETO_CLIPPED	| ETO_OPAQUE,&(MPanel.rcMisc),    		buffer,strlen(buffer),NULL);		if((HGDIOBJ)hgdiobj!=(HGDIOBJ)NULL && (HGDIOBJ)hgdiobj!=(HGDIOBJ)GDI_ERROR)			SelectObject(MPanel.hmdc,hgdiobj);		InvalidateRect(hPanelWnd, &(MPanel.rcMisc), FALSE);   }	if(MPanel.UpdateFlag & MP_UPDATE_MESSAGE){   }	if(MPanel.UpdateFlag==MP_UPDATE_ALL)		InvalidateRect(hPanelWnd, NULL, FALSE);	MPanel.UpdateFlag = MP_UPDATE_NONE;	gdi_unlock(); // gdi_lock}
4357	/local/tlutelli/issta_data/temp/c/2005_temp/2005/4357/b145888026ba74b152bd275692a491408aa2b59e/w32g_i.c/buggy/interface/w32g_i.c