summaryrefslogtreecommitdiff
path: root/same-android/src/main/java/com/orbekk/HelloAndroidActivity.java
diff options
context:
space:
mode:
authorKjetil Ørbekk <kjetil.orbekk@gmail.com>2012-01-18 21:08:26 +0100
committerKjetil Ørbekk <kjetil.orbekk@gmail.com>2012-01-18 21:08:26 +0100
commit5b27e3c7b289792b6520a099280a6c1bc28c20e8 (patch)
treed89b964dd0e4ea0f49c000e8853a15a8762e62e8 /same-android/src/main/java/com/orbekk/HelloAndroidActivity.java
parent6c150264b21eded212b9e2cf9c802b36c3f75144 (diff)
Hack: Use Same to synchronize state in the android app.
Diffstat (limited to 'same-android/src/main/java/com/orbekk/HelloAndroidActivity.java')
-rw-r--r--same-android/src/main/java/com/orbekk/HelloAndroidActivity.java8
1 files changed, 5 insertions, 3 deletions
diff --git a/same-android/src/main/java/com/orbekk/HelloAndroidActivity.java b/same-android/src/main/java/com/orbekk/HelloAndroidActivity.java
index cc90a3a..9df93d9 100644
--- a/same-android/src/main/java/com/orbekk/HelloAndroidActivity.java
+++ b/same-android/src/main/java/com/orbekk/HelloAndroidActivity.java
@@ -2,6 +2,7 @@ package com.orbekk;
import com.orbekk.net.Broadcaster;
import com.orbekk.same.ClientApp;
+import com.orbekk.same.ClientServiceImpl;
import android.app.Activity;
import android.os.Bundle;
@@ -26,15 +27,16 @@ public class HelloAndroidActivity extends Activity {
Log.i(TAG, "onCreate");
// setContentView(R.layout.main);
- setContentView(new GameView(this));
+ ClientApp client = new ClientApp();
+ ClientServiceImpl client_ = client.getClient(10015, "ClientNetwork",
+ "http://10.0.0.6:10010/");
+ setContentView(new GameView(this, client_));
// Broadcast broadcast = new Broadcast(this);
// broadcast.sendBroadcast("Broadcast test".getBytes(), 10010);
// Broadcaster broadcaster = new Broadcaster();
// Log.i(TAG, "Broadcast success: " + broadcaster.sendBroadcast(10010, "Broadcast test from Android".getBytes()));
//
-// ClientApp client = new ClientApp();
-// client.run(10015, "ClientNetwork", "http://10.0.0.6:10010/");
}
@Override