Add HDR state to app data in shortcut trampoline

This commit is contained in:
Cameron Gutman
2019-07-16 22:57:30 -07:00
parent e27129fc48
commit 0ac83e1cf7
4 changed files with 41 additions and 48 deletions

View File

@@ -4,8 +4,10 @@ import android.app.Activity;
import android.content.Intent;
import android.widget.Toast;
import com.limelight.AppView;
import com.limelight.Game;
import com.limelight.R;
import com.limelight.ShortcutTrampoline;
import com.limelight.binding.PlatformBinding;
import com.limelight.computers.ComputerManagerService;
import com.limelight.nvstream.http.ComputerDetails;
@@ -25,6 +27,25 @@ public class ServerHelper {
return computer.activeAddress;
}
public static Intent createPcShortcutIntent(Activity parent, ComputerDetails computer) {
Intent i = new Intent(parent, ShortcutTrampoline.class);
i.putExtra(AppView.NAME_EXTRA, computer.name);
i.putExtra(AppView.UUID_EXTRA, computer.uuid);
i.setAction(Intent.ACTION_DEFAULT);
return i;
}
public static Intent createAppShortcutIntent(Activity parent, ComputerDetails computer, NvApp app) {
Intent i = new Intent(parent, ShortcutTrampoline.class);
i.putExtra(AppView.NAME_EXTRA, computer.name);
i.putExtra(AppView.UUID_EXTRA, computer.uuid);
i.putExtra(Game.EXTRA_APP_NAME, app.getAppName());
i.putExtra(Game.EXTRA_APP_ID, ""+app.getAppId());
i.putExtra(Game.EXTRA_APP_HDR, app.isHdrSupported());
i.setAction(Intent.ACTION_DEFAULT);
return i;
}
public static Intent createStartIntent(Activity parent, NvApp app, ComputerDetails computer,
ComputerManagerService.ComputerManagerBinder managerBinder) {
Intent intent = new Intent(parent, Game.class);