mirror of
https://github.com/2009scape/2009Scape-mobile.git
synced 2025-12-19 21:10:11 -07:00
Gamepad pointer size is now dynamic !
This commit is contained in:
parent
97a8a11f80
commit
ee0b715061
4 changed files with 6 additions and 2 deletions
|
|
@ -922,7 +922,7 @@ public class BaseMainActivity extends LoggableActivity {
|
|||
return true;
|
||||
}
|
||||
|
||||
public void getMcScale() {
|
||||
public int getMcScale() {
|
||||
//Get the scale stored in game files, used auto scale if found or if the stored scaled is bigger than the authorized size.
|
||||
MCOptionUtils.load();
|
||||
String str = MCOptionUtils.get("guiScale");
|
||||
|
|
@ -935,6 +935,7 @@ public class BaseMainActivity extends LoggableActivity {
|
|||
}
|
||||
|
||||
if(gamepad != null) gamepad.notifyGUISizeChange(this.guiScale);
|
||||
return this.guiScale;
|
||||
}
|
||||
|
||||
public int handleGuiBar(int x, int y) {
|
||||
|
|
|
|||
|
|
@ -70,6 +70,9 @@ public class Gamepad {
|
|||
|
||||
this.gameActivity = gameActivity;
|
||||
pointerView = this.gameActivity.findViewById(R.id.console_pointer);
|
||||
pointerView.getDrawable().setFilterBitmap(false);
|
||||
notifyGUISizeChange(gameActivity.getMcScale());
|
||||
|
||||
|
||||
mouseThread = new Thread("Gamepad Thread"){
|
||||
long lastTime = System.nanoTime();
|
||||
|
|
|
|||
Binary file not shown.
|
Before Width: | Height: | Size: 258 B After Width: | Height: | Size: 695 B |
|
|
@ -41,7 +41,7 @@
|
|||
|
||||
<ImageView
|
||||
android:id="@+id/console_pointer"
|
||||
android:visibility="visible"
|
||||
android:visibility="invisible"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:srcCompat="@drawable/pointer" />
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue