Exemple #1
0
/*--------------------------------------------------------------------------*/
SIGNED SetupMenuClass::Message(const PegMessage &Mesg)
{
		BOOL bValueChanged = FALSE;
		char a[20];
		switch (Mesg.wType)
    {
	case PM_KEYRIGHT:
	case PM_KEYLEFT:
				switch(Mesg.iData)
				{
					case OKButtonID:
						printf("the input is %s",(char*)EditFrequency ->DataGet());
						break;
					case CancelButtonID:
						break;
					case CRTButtonID:
						break;

					case I2C0ButtonID:
						if (Mesg.wType == PM_KEYRIGHT)
						{
						}
						else
						{
						}

						break;

					case I2C3ButtonID:
						if (Mesg.wType == PM_KEYRIGHT)
						{
						}
						else
						{
						}
						break;
				}
				break;
	 case SIGNAL(OKButtonID, PSF_CLICKED):
		strcpy(a,EditFrequency ->DataGet());
		Frequency = (U32)atoi(a);
		strcpy(a,EditSymbolrate ->DataGet());
		SymboleRate = (U32)atoi(a);

		ModulationMethod = (U16)EditModulation ->GetModulationStatus();
		AddTransponder(Frequency,SymboleRate,ModulationMethod);
		break;

	case PM_CLOSE:
			BackToPreviousMenu();
			break;

	default:
		return PegWindow::Message(Mesg);
    }
    return 0;
}
Exemple #2
0
void cScanList::AddTransponders(cList<cChannel> *Channels)
{
  for (cChannel *ch = Channels->First(); ch; ch = Channels->Next(ch))
      AddTransponder(ch);
  Sort();
}