From c995d60d37032db3198b8496e186aa7a892dc7a8 Mon Sep 17 00:00:00 2001 From: Jeff Ames Date: Wed, 14 May 2008 05:11:23 +0000 Subject: Formatting cleanup. --- .../ConnectToGridServerDialog.cs | 2 +- .../GridServerConnectionManager.cs | 17 +++++++++-------- OpenSim/Grid/Manager/OpenGridServices.Manager/Main.cs | 12 ++++++------ 3 files changed, 16 insertions(+), 15 deletions(-) (limited to 'OpenSim/Grid/Manager/OpenGridServices.Manager') diff --git a/OpenSim/Grid/Manager/OpenGridServices.Manager/ConnectToGridServerDialog.cs b/OpenSim/Grid/Manager/OpenGridServices.Manager/ConnectToGridServerDialog.cs index da359a7..b6b2b64 100644 --- a/OpenSim/Grid/Manager/OpenGridServices.Manager/ConnectToGridServerDialog.cs +++ b/OpenSim/Grid/Manager/OpenGridServices.Manager/ConnectToGridServerDialog.cs @@ -39,7 +39,7 @@ namespace OpenGridServices.Manager protected virtual void OnResponse(object o, Gtk.ResponseArgs args) { - switch(args.ResponseId) { + switch (args.ResponseId) { case Gtk.ResponseType.Ok: MainClass.PendingOperations.Enqueue("connect_to_gridserver " + this.entry1.Text + " " + this.entry2.Text + " " + this.entry3.Text); break; diff --git a/OpenSim/Grid/Manager/OpenGridServices.Manager/GridServerConnectionManager.cs b/OpenSim/Grid/Manager/OpenGridServices.Manager/GridServerConnectionManager.cs index 995dd8c..a386fa8 100644 --- a/OpenSim/Grid/Manager/OpenGridServices.Manager/GridServerConnectionManager.cs +++ b/OpenSim/Grid/Manager/OpenGridServices.Manager/GridServerConnectionManager.cs @@ -55,7 +55,7 @@ namespace OpenGridServices.Manager LoginParams.Add(LoginParamsHT); XmlRpcRequest GridLoginReq = new XmlRpcRequest("manager_login",LoginParams); XmlRpcResponse GridResp = GridLoginReq.Send(ServerURL,3000); - if(GridResp.IsFault) { + if (GridResp.IsFault) { connected=false; return false; } else { @@ -87,14 +87,15 @@ namespace OpenGridServices.Manager // TODO - ERROR! } - for(int i=0; i<=rootnode.ChildNodes.Count; i++) + for (int i = 0; i <= rootnode.ChildNodes.Count; i++) { - if(rootnode.ChildNodes.Item(i).Name != "region") { + if (rootnode.ChildNodes.Item(i).Name != "region") + { // TODO - ERROR! - } else { + } + else + { TempRegionData = new RegionBlock(); - - } } } @@ -112,8 +113,8 @@ namespace OpenGridServices.Manager ShutdownParamsHT["session_id"]=this.SessionID.ToString(); ShutdownParams.Add(ShutdownParamsHT); XmlRpcRequest GridShutdownReq = new XmlRpcRequest("shutdown",ShutdownParams); - XmlRpcResponse GridResp = GridShutdownReq.Send(this.ServerURL,3000); - if(GridResp.IsFault) { + XmlRpcResponse GridResp = GridShutdownReq.Send(this.ServerURL, 3000); + if (GridResp.IsFault) { return false; } else { connected=false; diff --git a/OpenSim/Grid/Manager/OpenGridServices.Manager/Main.cs b/OpenSim/Grid/Manager/OpenGridServices.Manager/Main.cs index 33e577d..6b7a5ab 100644 --- a/OpenSim/Grid/Manager/OpenGridServices.Manager/Main.cs +++ b/OpenSim/Grid/Manager/OpenGridServices.Manager/Main.cs @@ -45,7 +45,7 @@ namespace OpenGridServices.Manager public static void DoMainLoop() { - while(!QuitReq) + while (!QuitReq) { Application.RunIteration(); } @@ -57,15 +57,15 @@ namespace OpenGridServices.Manager string cmd; char[] sep = new char[1]; sep[0]=' '; - while(!QuitReq) + while (!QuitReq) { operation=PendingOperations.Dequeue(); Console.WriteLine(operation); cmd = operation.Split(sep)[0]; - switch(cmd) { + switch (cmd) { case "connect_to_gridserver": win.SetStatus("Connecting to grid server..."); - if(gridserverConn.Connect(operation.Split(sep)[1],operation.Split(sep)[2],operation.Split(sep)[3])) { + if (gridserverConn.Connect(operation.Split(sep)[1], operation.Split(sep)[2], operation.Split(sep)[3])) { win.SetStatus("Connected OK with session ID:" + gridserverConn.SessionID); win.SetGridServerConnected(true); Thread.Sleep(3000); @@ -78,7 +78,7 @@ namespace OpenGridServices.Manager case "restart_gridserver": win.SetStatus("Restarting grid server..."); - if(gridserverConn.RestartServer()) { + if (gridserverConn.RestartServer()) { win.SetStatus("Restarted server OK"); Thread.Sleep(3000); win.SetStatus(""); @@ -89,7 +89,7 @@ namespace OpenGridServices.Manager case "shutdown_gridserver": win.SetStatus("Shutting down grid server..."); - if(gridserverConn.ShutdownServer()) { + if (gridserverConn.ShutdownServer()) { win.SetStatus("Grid server shutdown"); win.SetGridServerConnected(false); Thread.Sleep(3000); -- cgit v1.1