Enable penPaintingOnly flag for touch ui
This commit is contained in:
@@ -279,9 +279,7 @@ class Context {
|
||||
public static var maximizedSidebarWidth = 0;
|
||||
public static var cameraControls = ControlsOrbit;
|
||||
public static var dragDestination = 0;
|
||||
#if (krom_android || krom_ios)
|
||||
public static var penPaintingOnly = false; // Reject painting with finger when using pen
|
||||
#end
|
||||
|
||||
public static function selectMaterial(i: Int) {
|
||||
if (Project.materials.length <= i) return;
|
||||
|
||||
@@ -631,15 +631,14 @@ class UISidebar {
|
||||
Operator.shortcut(Config.keymap.brush_ruler + "+" + Config.keymap.action_paint, ShortcutDown) ||
|
||||
(Input.getPen().down() && !kb.down("alt"));
|
||||
|
||||
#if (krom_android || krom_ios)
|
||||
if (Input.getPen().down()) {
|
||||
Context.penPaintingOnly = true;
|
||||
if (Config.raw.touch_ui) {
|
||||
if (Input.getPen().down()) {
|
||||
Context.penPaintingOnly = true;
|
||||
}
|
||||
else if (Context.penPaintingOnly) {
|
||||
down = false;
|
||||
}
|
||||
}
|
||||
else if (Context.penPaintingOnly) {
|
||||
down = false;
|
||||
}
|
||||
#end
|
||||
|
||||
|
||||
#if arm_physics
|
||||
if (Context.tool == ToolParticle && Context.particlePhysics) {
|
||||
|
||||
Reference in New Issue
Block a user