%
% anyremote configuration file (Server-mode)
%

% STATUS unknown
% XTEST no
% SOUND no
% ENV no

GuiAppName=All-in-1
GuiAppType=Custom
GuiAppBinary=true
GuiAppProtocols=Server
GuiAppDesc=Manage a set of applications at once

[Protocol]=Server

(Init)=\
	Include($(CfgDir)/Utils/aliases-server.cfg);\
	Macro(SETUP_DEFAULT_POWER_MANAGEMENT);

(Connect)=Make(mode,_ALL_IN_ONE_1_);

ALLIN1MENU=Set(menu,add,All-in-1);

All-in-1=Make(mode,_ALL_IN_ONE_1_);
All-in-1($$)=Make(mode,_ALL_IN_ONE_1_)

[Mode]=_ALL_IN_ONE_1_

(EnterMode)=\
	Set(popup,show,Please wait);\
	Macro(ALL_IN_ONE_LAYOUT);\
	Macro(SHOWSW);


ALL_IN_ONE_LAYOUT=\
	Set(layout,default);\
	Set(icons,All-in-one,\
		1,plus,2,none,3,none,\
		4,none,5,none,6,none,\
		7,none,8,none,9,none,\
		*,question,0,none,#,no);\
	Set(title,press 1 to select application);\
	Set(status,);\
	Set(menu,replace,Power Off,Suspend);

* *=Set(text,replace,Help,Press 1, then choose application to manage)

Cancel=Exit

Back=\
	Set(text,close);\
	Macro(ALL_IN_ONE_LAYOUT);

Back($$)\
	=Set(list,close);\
	Macro(ALL_IN_ONE_LAYOUT);

Power Off=\
	Macro(DEFAULT_PC_SWITCHOFF);

Suspend=\
	Macro(DEFAULT_PC_SUSPEND);
	
Power Off($$)=\
	Macro(DEFAULT_PC_SWITCHOFF);

Suspend($$)=\
	Macro(DEFAULT_PC_SUSPEND);
	
SHOWSW=\
	Set(list,font,large);\
	ExecAndSet(list,replace,Applications,find $(CfgDir)/Server-mode -exec grep -l ALL_IN_ONE {} \;|grep -v .svn|xargs -i basename {}|grep -v all-in-one|sed 's/\.cfg//'|sed 's/$/,/'|sort);\
	Set(menu,replace,Select);\
	Set(popup,hide);

1=Set(popup,show,Please wait);\
	Macro(SHOWSW)
9=Exit

Push($$)  =Macro(SELECT);
Select($$)=Macro(SELECT);

SELECT=\
	Set(popup,show,Loading...);\
	Make(flush);\
	Set(title,);\
	Set(status,);\
	Include($(CfgDir)/Server-mode/$(Param).cfg);\
 	Macro((Init));\
 	Macro((Connect));\
  	Include($(CfgDir)/Server-mode/all-in-one.cfg);\
	Macro(ALLIN1MENU);\
	Set(popup,hide);
	
2=Make(none)
3=Make(none)
4=Make(none)
5=Make(none)
6=Make(none)
7=Make(none)
8=Make(none)
9=Make(none)

[ModeEnd]

[End]
