Add a floating button for the back menu#217
Add a floating button for the back menu#217ClassicOldSong merged 16 commits intoClassicOldSong:moonlight-noirfrom bonelag:moonlight-noir
Conversation
|
Thank you , but if you try compile, it won't work. Please fix the above reviews. |
Screenrecorder-2025-05-17-14-24-57-234.mp4it work😅 |
|
It won't work if you use the latest code. Just try compile the branch you're sending the PR from. |
|
The version I tested is an older version than the current one, but the logic is still the same. I hope you can refer to it and apply it in the latest version. |
|
Yes, but I have modified parts in a recent commit there that you removed. Please add them back. |
|
I don't quite understand what you mean, can you be more specific so I can provide what you need? |
| public static final String EXTRA_PORT = "Port"; | ||
| public static final String EXTRA_HTTPS_PORT = "HttpsPort"; | ||
| public static final String EXTRA_APP_NAME = "AppName"; | ||
| public static final String EXTRA_APP_UUID = "AppUUID"; |
There was a problem hiding this comment.
Please don't remove the newly added parts.......
|
|
||
| public static final String CLIPBOARD_IDENTIFIER = "ArtemisStreaming"; | ||
|
|
||
| private String appUUID; |
| host = Game.this.getIntent().getStringExtra(EXTRA_HOST); | ||
| port = Game.this.getIntent().getIntExtra(EXTRA_PORT, NvHTTP.DEFAULT_HTTP_PORT); | ||
| httpsPort = Game.this.getIntent().getIntExtra(EXTRA_HTTPS_PORT, 0); // 0 is treated as unknown | ||
| appUUID = Game.this.getIntent().getStringExtra(EXTRA_APP_UUID); |
| byte[] derCertData = Game.this.getIntent().getByteArrayExtra(EXTRA_SERVER_CERT); | ||
|
|
||
| app = new NvApp(appName != null ? appName : "app", appUUID, appId, appSupportsHdr); | ||
| app = new NvApp(appName != null ? appName : "app", appId, appSupportsHdr); |
| .setVirtualDisplay(vDisplay) | ||
| .setResolutionScaleFactor(prefConfig.resolutionScaleFactor) | ||
| .setApp(app) | ||
| .setEnableUltraLowLatency(prefConfig.enableUltraLowLatency) |
|
Ah sorry, I didn't submit the reviews |
|
oh i see, i copied and pasted the code of the old version so it caused an error, i will review it |
ClassicOldSong
left a comment
There was a problem hiding this comment.
Also, can we add a preference option to toggle the floating button? If it can be toggled in the back menu dynamically it's even better.
| private float dX, dY; | ||
| private boolean isMovingButton = false; | ||
| private static final float CLICK_ACTION_THRESHOLD = 5; | ||
| private float startX, startY; |
There was a problem hiding this comment.
Class member names should reflect what they're actually for. dX/dY, startX/startY are just too generic.
There was a problem hiding this comment.
Also here, please change them to a more specific name.
| newX = getWindow().getDecorView().getWidth() - view.getWidth(); | ||
| } | ||
| if (newY > getWindow().getDecorView().getHeight() - view.getHeight()) { | ||
| newY = getWindow().getDecorView().getHeight() - view.getHeight(); |
There was a problem hiding this comment.
The same value can be stored in a local variable, no need to get and calcuoate them everytime. The original Moonlight code did this but let's keep this bad habbit out of our new codes.
bonelag
left a comment
There was a problem hiding this comment.
since I'm not very good at coding I merged it with the back menu's hide/show setting
| streamView.setClipToOutline(true); | ||
| } | ||
| } | ||
| private void updateFloatingButtonVisibility() { |
There was a problem hiding this comment.
since I'm not very good at coding I merged it with the back menu hide/show setting
|
I tested it because I needed to use it, so it's not very professional. If you have any ideas for changes, just do it to upgrade the app to be more complete. |
README.md
Outdated
| Artemis is currently the best fork of Moonlight with loads of optimizations for office usage. | ||
|
|
||
| A more seamless experience with virtual display will be Artemis paired with [Apollo](https://github.com/ClassicOldSong/Apollo). | ||
| A more seamless experience with virtual display will be Artemis paired with [Artemis](https://github.com/ClassicOldSong/Artemis). |
There was a problem hiding this comment.
Artemis paired with Artemis 🤣
It should remain Apollo, and all of the followings.
There was a problem hiding this comment.
Here this is still not fixed. You can just revert the edits to this file.
|
It seems you have messed up all the Vietnamese translations... You got Apollo and Artemis swapped everywhere. I don't understand Vietnamese so you have to fix it yourself. |
|
Any updates? |
|
i will fix this now |
README.md
Outdated
| Artemis is currently the best fork of Moonlight with loads of optimizations for office usage. | ||
|
|
||
| A more seamless experience with virtual display will be Artemis paired with [Apollo](https://github.com/ClassicOldSong/Apollo). | ||
| A more seamless experience with virtual display will be Artemis paired with [Artemis](https://github.com/ClassicOldSong/Artemis). |
There was a problem hiding this comment.
Here this is still not fixed. You can just revert the edits to this file.
| private float dX, dY; | ||
| private boolean isMovingButton = false; | ||
| private static final float CLICK_ACTION_THRESHOLD = 5; | ||
| private float startX, startY; |
There was a problem hiding this comment.
Also here, please change them to a more specific name.
There was a problem hiding this comment.
Please don't add CI yet... It causes sign key change and will force everyone to reinstall.
There was a problem hiding this comment.
I just build to find bugs, please ignore it
|
Please discuss first if you're adding anything, or I'll only cherry picking relvant commits. |
|
You can build locally to test, no need to rely on the CI and constantly push any minor changes. |
|
i want to do that too but my pc is really bad |
|
😢 |



My pull request