bool CGUIWindowSystemInfo::OnMessage(CGUIMessage& message) { switch ( message.GetMessage() ) { case GUI_MSG_WINDOW_INIT: { CGUIWindow::OnMessage(message); ResetLabels(); SET_CONTROL_LABEL(52, "XBMC " + g_infoManager.GetLabel(SYSTEM_BUILD_VERSION) + " (Compiled : " + g_infoManager.GetLabel(SYSTEM_BUILD_DATE)+")"); return true; } break; case GUI_MSG_WINDOW_DEINIT: { CGUIWindow::OnMessage(message); m_diskUsage.clear(); return true; } break; case GUI_MSG_FOCUSED: { CGUIWindow::OnMessage(message); int focusedControl = GetFocusedControlID(); if (focusedControl >= CONTROL_START && focusedControl <= CONTROL_END) m_section = focusedControl; return true; } break; } return CGUIWindow::OnMessage(message); }
void DPO_CubeExtractGridPS::SetMenuData(DPO_CubeExtractGrid& inData) { MenuBaseC::SetMenuData(inData); cubeInputUI.SetCubeInput(inData); ResetLabels(); gridXUI.SetChoice(inData.gridX); gridYUI.SetChoice(inData.gridY); logInterpUI.SetValue(inData.logInterp); extractValMSUI.SetValue(inData.extractValMS, inData.exposedExtractVal); SetAllSensitive(); }
void YahtZFrame::StartNewGame() { Game.Reset(); BonusLabel->SetLabel(wxT("0")); DisableButtons(); ResetLabels(); for (int i = 0; i < 13; i++) { ButtonsEnabled[i] = true; } RollButton->Enable(); RollButton->SetLabel(wxString::Format(wxT("ROLL (%i)"), Game.GetRollCount())); Dice1->SetBitmap(wxBitmap()); Dice2->SetBitmap(wxBitmap()); Dice3->SetBitmap(wxBitmap()); Dice4->SetBitmap(wxBitmap()); Dice5->SetBitmap(wxBitmap()); }
bool CGUIWindowSystemInfo::OnMessage(CGUIMessage& message) { switch (message.GetMessage()) { case GUI_MSG_WINDOW_INIT: { CGUIWindow::OnMessage(message); SET_CONTROL_LABEL(52, CSysInfo::GetAppName() + " " + CSysInfo::GetVersion()); SET_CONTROL_LABEL(53, CSysInfo::GetBuildDate()); CONTROL_ENABLE_ON_CONDITION(CONTROL_BT_PVR, PVR::CPVRManager::GetInstance().IsStarted()); return true; } break; case GUI_MSG_WINDOW_DEINIT: { CGUIWindow::OnMessage(message); m_diskUsage.clear(); return true; } break; case GUI_MSG_FOCUSED: { CGUIWindow::OnMessage(message); int focusedControl = GetFocusedControlID(); if (m_section != focusedControl && focusedControl >= CONTROL_START && focusedControl <= CONTROL_END) { ResetLabels(); m_section = focusedControl; } return true; } break; } return CGUIWindow::OnMessage(message); }
bool CGUIWindowSystemInfo::OnMessage(CGUIMessage& message) { switch ( message.GetMessage() ) { case GUI_MSG_WINDOW_INIT: { CGUIWindow::OnMessage(message); SET_CONTROL_LABEL(52, CSysInfo::GetAppName() + " " + g_infoManager.GetLabel(SYSTEM_BUILD_VERSION).c_str() + " (Compiled: " + g_infoManager.GetLabel(SYSTEM_BUILD_DATE).c_str() +")"); CONTROL_ENABLE_ON_CONDITION(CONTROL_BT_PVR, PVR::CPVRManager::Get().IsStarted()); return true; } break; case GUI_MSG_WINDOW_DEINIT: { CGUIWindow::OnMessage(message); m_diskUsage.clear(); return true; } break; case GUI_MSG_FOCUSED: { CGUIWindow::OnMessage(message); int focusedControl = GetFocusedControlID(); if (m_section != focusedControl && focusedControl >= CONTROL_START && focusedControl <= CONTROL_END) { ResetLabels(); m_section = focusedControl; } return true; } break; } return CGUIWindow::OnMessage(message); }
void CGUIWindowSystemInfo::FrameMove() { ResetLabels(); int i = 2; if (m_section == CONTROL_BT_DEFAULT) { SET_CONTROL_LABEL(40,g_localizeStrings.Get(20154)); SetControlLabel(i++, "%s: %s", 158, SYSTEM_FREE_MEMORY); SetControlLabel(i++, "%s: %s", 150, NETWORK_IP_ADDRESS); SetControlLabel(i++, "%s %s", 13287, SYSTEM_SCREEN_RESOLUTION); #ifdef HAS_SYSINFO SetControlLabel(i++, "%s %s", 13283, SYSTEM_KERNEL_VERSION); #endif SetControlLabel(i++, "%s: %s", 12390, SYSTEM_UPTIME); SetControlLabel(i++, "%s: %s", 12394, SYSTEM_TOTALUPTIME); SetControlLabel(i++, "%s: %s", 12395, SYSTEM_BATTERY_LEVEL); } else if (m_section == CONTROL_BT_STORAGE) { SET_CONTROL_LABEL(40,g_localizeStrings.Get(20155)); if (m_diskUsage.size() == 0) m_diskUsage = g_mediaManager.GetDiskUsage(); for (size_t d = 0; d < m_diskUsage.size(); d++) { SET_CONTROL_LABEL(i++, m_diskUsage[d]); } } else if (m_section == CONTROL_BT_NETWORK) { SET_CONTROL_LABEL(40,g_localizeStrings.Get(20158)); #ifdef HAS_SYSINFO SET_CONTROL_LABEL(i++, g_infoManager.GetLabel(NETWORK_LINK_STATE)); SetControlLabel(i++, "%s: %s", 149, NETWORK_MAC_ADDRESS); #endif SetControlLabel(i++, "%s: %s", 150, NETWORK_IP_ADDRESS); SetControlLabel(i++, "%s: %s", 13159, NETWORK_SUBNET_MASK); SetControlLabel(i++, "%s: %s", 13160, NETWORK_GATEWAY_ADDRESS); SetControlLabel(i++, "%s: %s", 13161, NETWORK_DNS1_ADDRESS); SetControlLabel(i++, "%s: %s", 20307, NETWORK_DNS2_ADDRESS); SetControlLabel(i++, "%s %s", 13295, SYSTEM_INTERNET_STATE); } else if (m_section == CONTROL_BT_VIDEO) { SET_CONTROL_LABEL(40,g_localizeStrings.Get(20159)); #ifdef HAS_SYSINFO SET_CONTROL_LABEL(i++,g_infoManager.GetLabel(SYSTEM_VIDEO_ENCODER_INFO)); SetControlLabel(i++, "%s %s", 13287, SYSTEM_SCREEN_RESOLUTION); #endif #ifndef HAS_DX SetControlLabel(i++, "%s %s", 22007, SYSTEM_RENDER_VENDOR); SetControlLabel(i++, "%s %s", 22009, SYSTEM_RENDER_VERSION); #else SetControlLabel(i++, "%s %s", 22023, SYSTEM_RENDER_VENDOR); SetControlLabel(i++, "%s %s", 22024, SYSTEM_RENDER_VERSION); #endif SetControlLabel(i++, "%s %s", 22010, SYSTEM_GPU_TEMPERATURE); } else if (m_section == CONTROL_BT_HARDWARE) { SET_CONTROL_LABEL(40,g_localizeStrings.Get(20160)); #ifdef HAS_SYSINFO SET_CONTROL_LABEL(i++, g_sysinfo.GetXBVerInfo()); SetControlLabel(i++, "%s %s", 22011, SYSTEM_CPU_TEMPERATURE); SetControlLabel(i++, "%s %s", 13284, SYSTEM_CPUFREQUENCY); #endif SetControlLabel(i++, "%s %s", 13271, SYSTEM_CPU_USAGE); i++; // empty line SetControlLabel(i++, "%s: %s", 22012, SYSTEM_TOTAL_MEMORY); SetControlLabel(i++, "%s: %s", 158, SYSTEM_FREE_MEMORY); } else if(m_section == CONTROL_BT_PVR) { SET_CONTROL_LABEL(40,g_localizeStrings.Get(19166)); int i = 2; SetControlLabel(i++, "%s: %s", 19120, PVR_BACKEND_NUMBER); i++; // empty line SetControlLabel(i++, "%s: %s", 19012, PVR_BACKEND_NAME); SetControlLabel(i++, "%s: %s", 19114, PVR_BACKEND_VERSION); SetControlLabel(i++, "%s: %s", 19115, PVR_BACKEND_HOST); SetControlLabel(i++, "%s: %s", 19116, PVR_BACKEND_DISKSPACE); SetControlLabel(i++, "%s: %s", 19019, PVR_BACKEND_CHANNELS); SetControlLabel(i++, "%s: %s", 19163, PVR_BACKEND_RECORDINGS); SetControlLabel(i++, "%s: %s", 19025, PVR_BACKEND_TIMERS); } SET_CONTROL_LABEL(52, "XBMC "+g_infoManager.GetLabel(SYSTEM_BUILD_VERSION)+" (Compiled : "+g_infoManager.GetLabel(SYSTEM_BUILD_DATE)+")"); CGUIWindow::FrameMove(); }
int dfww(int argc, char *argv[], int retc, char *retv[]) /*************/ { int firstindex; int lastindex; int step; int ctrace; int do_ww; int local_color; int imag_on; int redoDscale; int color_traces; int index=1; int maxindex=nblocks * specperblock; double save_sc, save_wc, save_sc2, save_wc2; (void) retc; (void) retv; redoDscale = dscale_onscreen(); Wturnoff_buttons(); plot = (argv[0][0] == 'p'); do_ww = (argv[0][2] == 'w'); if (Bnmr && !plot) return(COMPLETE); revflag = 0; if(initfid(plot+1)) return(ERROR); dispcalib = (float) (mnumypnts-ymin) / (float) wc2max; if (init_vars2()) return(ERROR); clearMspec(); checkinput(argc,argv,&firstindex,&lastindex,&step,&imag_on,&color_traces); if (!plot) setwindows(argv); if ((firstindex < 1) || (firstindex > maxindex)) { Werrprintf("spectrum %d does not exist",firstindex); return(ERROR); } save_sc=sc; save_wc=wc; save_sc2=sc2; save_wc2=wc2; if (lastindex < firstindex) lastindex = firstindex; if (lastindex > maxindex) lastindex = maxindex; //setscwc(firstindex,lastindex,step); if(plot) setscwc(firstindex,lastindex,step); else setscwc_new(firstindex,lastindex,step); setspecmaxmin(); disp_specIndex(firstindex); /* Need to change this for multiple traces... */ get_fid_color(argc,argv,&local_color,imag_on); ctrace = index = firstindex; if (!plot && inRepaintMode && redoDscale) new_dscale(FALSE,TRUE); if (do_ww) if (init_whitewash(mnumxpnts)) do_ww = FALSE; while ((ctrace <= lastindex) && !interuption) { if(plot) exp_factors(FALSE); else calcDisplayPars(); if(color_traces) local_color=((index % (NUM_AV_COLORS-2)) + FIRST_AV_COLOR + 1); if (calc_fid(ctrace-1)) return(ERROR); if (imag_on) imagdisp(local_color, do_ww); else fiddisp(local_color, do_ww); if(plot) { sc += ho; if (!horizontal) sc2 += vo; } else { dss_sc += ho; if (!horizontal) dss_sc2 += vo; } ctrace += step; index++; } if (!plot) { ResetLabels(); DispField(FIELD1,PARAM_COLOR,"vf",vs,1); InitVal(FIELD2,HORIZ,SP_NAME, PARAM_COLOR,UNIT4, SP_NAME, PARAM_COLOR,SCALED,2); InitVal(FIELD3,HORIZ,WP_NAME, PARAM_COLOR,UNIT4, WP_NAME, PARAM_COLOR,SCALED,2); if (firstindex != lastindex) { DispField(FIELD4,PARAM_COLOR,"first",(double) firstindex,0); DispField(FIELD5,PARAM_COLOR,"last",(double) lastindex,0); DispField(FIELD6,PARAM_COLOR,"step",(double) step,0); } } if (plot) amove(0,0); else { exit_display(); Wsetgraphicsdisplay("dfs"); } endgraphics(); sc=save_sc; wc=save_wc; sc2=save_sc2; wc2=save_wc2; P_setreal(CURRENT,"sc",sc,0); P_setreal(CURRENT,"wc",wc,0); P_setreal(CURRENT,"sc2",sc2,0); P_setreal(CURRENT,"wc2",wc2,0); if (do_ww) close_whitewash(); if (freebuffers()) return(ERROR); appendvarlist("dss_sc,dss_wc,sc,wc,vo,ho"); return(COMPLETE); }