Skip to content
Permalink
Browse files

rm unused code

  • Loading branch information...
weihuoya committed Apr 17, 2019
1 parent 04ebee6 commit 47e776d3789f7127fd2e80bc4988653a3ef001c2
@@ -195,7 +195,7 @@ public static void launch(FragmentActivity activity, GameFile gameFile)
launcher.putExtra(EXTRA_SELECTED_TITLE, gameFile.getTitle());
launcher.putExtra(EXTRA_SELECTED_GAMEID, gameFile.getGameId());
launcher.putExtra(EXTRA_PLATFORM, gameFile.getPlatform());
activity.startActivityForResult(launcher, MainPresenter.REQUEST_EMULATE_GAME);
activity.startActivity(launcher);
}

@Override
@@ -131,19 +131,6 @@ public void setVersionString(String version)
mToolbar.setSubtitle(version);
}

@Override
public void refreshFragmentScreenshot(int fragmentPosition)
{
// Invalidate Picasso image so that the new screenshot is animated in.
Platform platform = Platform.fromPosition(mViewPager.getCurrentItem());
PlatformGamesView fragment = getPlatformGamesView(platform);

if (fragment != null)
{
fragment.refreshScreenshotAtPosition(fragmentPosition);
}
}

@Override
public void launchSettingsActivity(MenuTag menuTag)
{
@@ -173,10 +160,6 @@ protected void onActivityResult(int requestCode, int resultCode, Intent result)
mPresenter.onDirectorySelected(FileBrowserHelper.getSelectedDirectory(result));
}
break;

case MainPresenter.REQUEST_EMULATE_GAME:
mPresenter.refreshFragmentScreenshot(resultCode);
break;
}
}

@@ -15,7 +15,6 @@
public final class MainPresenter
{
public static final int REQUEST_ADD_DIRECTORY = 1;
public static final int REQUEST_EMULATE_GAME = 2;

private final MainView mView;
private final Context mContext;
@@ -105,9 +104,4 @@ public void onDirectorySelected(String dir)
{
mDirToAdd = dir;
}

public void refreshFragmentScreenshot(int resultCode)
{
mView.refreshFragmentScreenshot(resultCode);
}
}
@@ -17,15 +17,6 @@
*/
void setVersionString(String version);

/**
* Tell the view to tell the currently displayed {@link android.support.v4.app.Fragment}
* to refresh the screenshot at the given position in its list of games.
*
* @param fragmentPosition An index corresponding to the list or grid of games.
*/
void refreshFragmentScreenshot(int fragmentPosition);


void launchSettingsActivity(MenuTag menuTag);

void launchFileListActivity();
@@ -131,12 +131,6 @@ public void setVersionString(String version)
mBrowseFragment.setTitle(version);
}

@Override
public void refreshFragmentScreenshot(int fragmentPosition)
{
mRowsAdapter.notifyArrayItemRangeChanged(0, mRowsAdapter.size());
}

@Override
public void launchSettingsActivity(MenuTag menuTag)
{
@@ -177,10 +171,6 @@ protected void onActivityResult(int requestCode, int resultCode, Intent result)
mPresenter.onDirectorySelected(FileBrowserHelper.getSelectedDirectory(result));
}
break;

case MainPresenter.REQUEST_EMULATE_GAME:
mPresenter.refreshFragmentScreenshot(resultCode);
break;
}
}

0 comments on commit 47e776d

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