Skip to content
Permalink
Browse files

GameDetailsDialog: Remove the screenshot ImageView

It takes up a lot of space on the screen, and the functionality for
saving these screenshots isn't in Dolphin anymore as far as I can tell.
  • Loading branch information
JosJuice committed Jun 16, 2019
1 parent 100e7e2 commit 84e616337d7bee085546f7b7f1d037eea6d5312e
@@ -42,7 +42,6 @@ public Dialog onCreateDialog(Bundle savedInstanceState)
ViewGroup contents = (ViewGroup) getActivity().getLayoutInflater()
.inflate(R.layout.dialog_game_details, null);

final ImageView imageGameScreen = contents.findViewById(R.id.image_game_screen);
ImageView banner = contents.findViewById(R.id.banner);

TextView textTitle = contents.findViewById(R.id.text_game_title);
@@ -71,15 +70,6 @@ public Dialog onCreateDialog(Bundle savedInstanceState)
EmulationActivity.launch(getActivity(), gameFile);
});

// Fill in the view contents.
Picasso.get()
.load(getArguments().getString(gameFile.getScreenshotPath()))
.fit()
.centerCrop()
.noFade()
.noPlaceholder()
.into(imageGameScreen);

PicassoUtils.loadGameBanner(banner, gameFile);

builder.setView(contents);
@@ -54,11 +54,4 @@ public String getCustomCoverPath()
{
return getPath().substring(0, getPath().lastIndexOf(".")) + ".cover.png";
}

public String getScreenshotPath()
{
String gameId = getGameId();
return "file://" + Environment.getExternalStorageDirectory().getPath() +
"/dolphin-emu/ScreenShots/" + gameId + "/" + gameId + "-1.png";
}
}
@@ -2,15 +2,15 @@
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_height="match_parent"
android:layout_height="wrap_content"
android:layout_width="match_parent"
android:paddingStart="24dp"
android:paddingEnd="24dp"
android:transitionName="card_game">

<RelativeLayout
android:layout_width="480dp"
android:layout_height="match_parent">
android:layout_height="wrap_content">

<ImageView
android:id="@+id/banner"
@@ -21,25 +21,11 @@
android:layout_marginBottom="16dp"
tools:src="@drawable/placeholder_banner"/>

<ImageView
android:id="@+id/image_game_screen"
android:layout_width="match_parent"
android:layout_height="320dp"
android:layout_alignParentEnd="true"
android:layout_alignParentLeft="true"
android:layout_alignParentRight="true"
android:layout_alignParentStart="true"
android:layout_alignParentTop="true"
android:transitionName="image_game_screen"
tools:scaleType="centerCrop"
tools:src="@drawable/placeholder_screenshot"/>

<TextView
android:id="@+id/text_game_title"
style="@android:style/TextAppearance.Material.Headline"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/image_game_screen"
android:layout_marginTop="24dp"
android:ellipsize="end"
tools:text="Rhythm Heaven Fever"/>
@@ -111,7 +97,6 @@
android:id="@+id/button_launch"
android:layout_width="56dp"
android:layout_height="56dp"
android:layout_alignBottom="@+id/image_game_screen"
android:layout_alignEnd="@+id/text_game_title"
android:layout_marginBottom="-28dp"
android:src="@drawable/ic_play"

0 comments on commit 84e6163

Please sign in to comment.
You can’t perform that action at this time.