forked from wheremyfoodat/Panda3DS
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add scripting support for Android (wheremyfoodat#369)
* Lua Patcher and code editor: initial commit * Code Editor + Lua Patchs + Fixes * some fixes * bonk --------- Co-authored-by: wheremyfoodat <44909372+wheremyfoodat@users.noreply.github.com>
- Loading branch information
1 parent
23770e2
commit b571801
Showing
35 changed files
with
1,639 additions
and
54 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
28 changes: 28 additions & 0 deletions
28
src/pandroid/app/src/main/java/com/panda3ds/pandroid/app/base/BottomDialogFragment.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
package com.panda3ds.pandroid.app.base; | ||
|
||
import android.app.Dialog; | ||
import android.os.Bundle; | ||
import android.view.Gravity; | ||
|
||
import androidx.annotation.NonNull; | ||
import androidx.annotation.Nullable; | ||
import androidx.fragment.app.DialogFragment; | ||
|
||
import com.panda3ds.pandroid.R; | ||
|
||
public class BottomDialogFragment extends DialogFragment { | ||
@Override | ||
public int getTheme() { | ||
return R.style.AlertDialog; | ||
} | ||
|
||
@NonNull | ||
@Override | ||
public Dialog onCreateDialog(@Nullable Bundle savedInstanceState) { | ||
Dialog dialog = super.onCreateDialog(savedInstanceState); | ||
dialog.getWindow().setGravity(Gravity.CENTER | Gravity.BOTTOM); | ||
dialog.getWindow().getAttributes().y = Math.round(getContext().getResources().getDisplayMetrics().density * 15); | ||
|
||
return dialog; | ||
} | ||
} |
Oops, something went wrong.