⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 radios.cpp

📁 DOS下的图形界面开发包
💻 CPP
字号:
#include "radios.h"

//33333333333333333333333333333333333333333333333333333333333333333333333/
radios_group_class::radios_group_class (int ID,char *title_hotkey,int left,int top,int width,int height )
	:group_class(ID,title_hotkey,left,top,width,height )
{
	flag=TRUE;
}

int radios_group_class::key_pressed_handler  (int key_num)
{
	switch (key_num) {
		case SPACEKEY:
			return TRUE;
		default:return group_class::key_pressed_handler(key_num);
	}
}


int radios_group_class::control_change_value	(int new_value )
{   //for first coming
	if ( pcontrol_current_selected !=NULL ) {
		if (pcontrol_current_selected->current_value !=pcontrol_current_selected->min_value)
			if (!flag)pcontrol_current_selected->control_change_value (pcontrol_current_selected->min_value);
			else pcontrol_current_selected->unselect();
	}
	flag =FALSE;
	return group_class::control_change_value	(new_value );
}

int radios_group_class::msg_handler 	(MSG& message)
{
	switch (message.Action){
		case GroupValueChangedMSG:
			if (message.fptr == this ) {
//				if (pcontrol_current_selected->current_value ==pcontrol_current_selected->min_value)
				{
					pcontrol_current_selected->control_change_value (pcontrol_current_selected->max_value);
				}
				return TRUE;
			}
			break;
		default: ;// return FALSE;
	}
	return group_class::msg_handler (message);
//	return FALSE;
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -