diff --git a/app/src/main/java/com/limelight/PcView.java b/app/src/main/java/com/limelight/PcView.java
index 2017e078..d090144e 100644
--- a/app/src/main/java/com/limelight/PcView.java
+++ b/app/src/main/java/com/limelight/PcView.java
@@ -40,11 +40,13 @@ import android.widget.AdapterView.OnItemClickListener;
import android.widget.Button;
import android.widget.GridView;
import android.widget.ImageButton;
+import android.widget.RelativeLayout;
import android.widget.Toast;
import android.widget.AdapterView.AdapterContextMenuInfo;
public class PcView extends Activity {
private ImageButton settingsButton, addComputerButton;
+ private RelativeLayout noPcFoundLayout;
private GridView pcGrid;
private PcGridAdapter pcGridAdapter;
private ComputerManagerService.ComputerManagerBinder managerBinder;
@@ -141,6 +143,13 @@ public class PcView extends Activity {
}
});
+ noPcFoundLayout = (RelativeLayout) findViewById(R.id.no_pc_found_layout);
+ if (pcGridAdapter.getCount() == 0) {
+ noPcFoundLayout.setVisibility(View.VISIBLE);
+ }
+ else {
+ noPcFoundLayout.setVisibility(View.INVISIBLE);
+ }
pcGridAdapter.notifyDataSetChanged();
}
@@ -542,6 +551,9 @@ public class PcView extends Activity {
else {
// Add a new entry
pcGridAdapter.addComputer(new ComputerObject(details));
+
+ // Remove the "Discovery in progress" view
+ noPcFoundLayout.setVisibility(View.INVISIBLE);
}
// Notify the view that the data has changed
diff --git a/app/src/main/res/layout-land/activity_pc_view.xml b/app/src/main/res/layout-land/activity_pc_view.xml
index e30e2ba1..06ad7c52 100644
--- a/app/src/main/res/layout-land/activity_pc_view.xml
+++ b/app/src/main/res/layout-land/activity_pc_view.xml
@@ -8,17 +8,43 @@
android:paddingTop="@dimen/activity_vertical_margin"
tools:context=".PcView" >
-
+ android:layout_toRightOf="@+id/settingsButton">
+
+
+
+
+
+
-
+ android:layout_toRightOf="@+id/settingsButton">
+
+
+
+
+
+