package b4a.limitbardemo;


import anywheresoftware.b4a.BA;
import anywheresoftware.b4a.B4AClass;
import anywheresoftware.b4a.BALayout;
import anywheresoftware.b4a.debug.*;

public class limitbar extends B4AClass.ImplB4AClass implements BA.SubDelegator{
    private static java.util.HashMap<String, java.lang.reflect.Method> htSubs;
    private void innerInitialize(BA _ba) throws Exception {
        if (ba == null) {
            ba = new anywheresoftware.b4a.ShellBA(_ba, this, htSubs, "b4a.limitbardemo.limitbar");
            if (htSubs == null) {
                ba.loadHtSubs(this.getClass());
                htSubs = ba.htSubs;
            }
            
        }
        if (BA.isShellModeRuntimeCheck(ba)) 
			   this.getClass().getMethod("_class_globals", b4a.limitbardemo.limitbar.class).invoke(this, new Object[] {null});
        else
            ba.raiseEvent2(null, true, "class_globals", false);
    }

 
    public void  innerInitializeHelper(anywheresoftware.b4a.BA _ba) throws Exception{
        innerInitialize(_ba);
    }
    public Object callSub(String sub, Object sender, Object[] args) throws Exception {
        return BA.SubDelegator.SubNotFound;
    }
public anywheresoftware.b4a.keywords.Common __c = null;
public Object _mcallback = null;
public String _meventname = "";
public int _mwidth = 0;
public int _mheight = 0;
public int _mradius = 0;
public anywheresoftware.b4a.objects.PanelWrapper _ltbpanelback = null;
public anywheresoftware.b4a.objects.PanelWrapper _ltbpanelfront = null;
public anywheresoftware.b4a.objects.drawable.CanvasWrapper _cvspanelback = null;
public anywheresoftware.b4a.objects.drawable.CanvasWrapper _cvspanelfront = null;
public anywheresoftware.b4a.objects.drawable.CanvasWrapper.RectWrapper _rectpanelfront = null;
public int _mbackgroundcolor = 0;
public anywheresoftware.b4a.objects.drawable.ColorDrawable _cdwbackground = null;
public int _mbacklinecolor = 0;
public int _mfrontlinecolor = 0;
public int _mmargin = 0;
public int _x0 = 0;
public int _y0 = 0;
public int _x1 = 0;
public int _y1 = 0;
public int _y2 = 0;
public int _mmaxvalue = 0;
public double _mscale = 0;
public int[] _mlimit = null;
public int[] _positionpixels = null;
public anywheresoftware.b4a.objects.drawable.CanvasWrapper.PathWrapper[] _paths = null;
public int _posindex = 0;
public b4a.limitbardemo.main _main = null;
public String  _initialize(b4a.limitbardemo.limitbar __ref,anywheresoftware.b4a.BA _ba,Object _callback,String _eventname) throws Exception{
__ref = this;
innerInitialize(_ba);
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "initialize"))
	return (String) Debug.delegate(ba, "initialize", new Object[] {_ba,_callback,_eventname});
RDebugUtils.currentLine=917504;
 //BA.debugLineNum = 917504;BA.debugLine="Public Sub Initialize(Callback As Object, EventNam";
RDebugUtils.currentLine=917505;
 //BA.debugLineNum = 917505;BA.debugLine="mCallback = Callback";
__ref._mcallback = _callback;
RDebugUtils.currentLine=917506;
 //BA.debugLineNum = 917506;BA.debugLine="mEventName = EventName";
__ref._meventname = _eventname;
RDebugUtils.currentLine=917509;
 //BA.debugLineNum = 917509;BA.debugLine="mBackgroundColor = Colors.Blue";
__ref._mbackgroundcolor = __c.Colors.Blue;
RDebugUtils.currentLine=917510;
 //BA.debugLineNum = 917510;BA.debugLine="mBackLineColor = Colors.Black";
__ref._mbacklinecolor = __c.Colors.Black;
RDebugUtils.currentLine=917511;
 //BA.debugLineNum = 917511;BA.debugLine="mFrontLineColor = Colors.RGB(51, 181, 229)";
__ref._mfrontlinecolor = __c.Colors.RGB((int) (51),(int) (181),(int) (229));
RDebugUtils.currentLine=917512;
 //BA.debugLineNum = 917512;BA.debugLine="mMargin = 15dip";
__ref._mmargin = __c.DipToCurrent((int) (15));
RDebugUtils.currentLine=917513;
 //BA.debugLineNum = 917513;BA.debugLine="mMaxValue = 100";
__ref._mmaxvalue = (int) (100);
RDebugUtils.currentLine=917514;
 //BA.debugLineNum = 917514;BA.debugLine="mLimit(0) = 0";
__ref._mlimit[(int) (0)] = (int) (0);
RDebugUtils.currentLine=917515;
 //BA.debugLineNum = 917515;BA.debugLine="mLimit(1) = mMaxValue";
__ref._mlimit[(int) (1)] = __ref._mmaxvalue;
RDebugUtils.currentLine=917516;
 //BA.debugLineNum = 917516;BA.debugLine="End Sub";
return "";
}
public String  _setfrontlinecolor(b4a.limitbardemo.limitbar __ref,int _frontlinecolor) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "setfrontlinecolor"))
	return (String) Debug.delegate(ba, "setfrontlinecolor", new Object[] {_frontlinecolor});
RDebugUtils.currentLine=2621440;
 //BA.debugLineNum = 2621440;BA.debugLine="Public Sub setFrontLineColor(FrontLineColor As Int";
RDebugUtils.currentLine=2621441;
 //BA.debugLineNum = 2621441;BA.debugLine="mFrontLineColor = FrontLineColor";
__ref._mfrontlinecolor = _frontlinecolor;
RDebugUtils.currentLine=2621442;
 //BA.debugLineNum = 2621442;BA.debugLine="If ltbPanelBack.IsInitialized Then";
if (__ref._ltbpanelback.IsInitialized()) { 
RDebugUtils.currentLine=2621443;
 //BA.debugLineNum = 2621443;BA.debugLine="DrawCursors";
__ref._drawcursors(null);
 };
RDebugUtils.currentLine=2621445;
 //BA.debugLineNum = 2621445;BA.debugLine="End Sub";
return "";
}
public String  _addtoparent(b4a.limitbardemo.limitbar __ref,anywheresoftware.b4a.objects.ActivityWrapper _parent,int _left,int _top,int _width,int _height,int _backgroundcolor,int _radius) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "addtoparent"))
	return (String) Debug.delegate(ba, "addtoparent", new Object[] {_parent,_left,_top,_width,_height,_backgroundcolor,_radius});
RDebugUtils.currentLine=1048576;
 //BA.debugLineNum = 1048576;BA.debugLine="Public Sub AddToParent(Parent As Activity, Left As";
RDebugUtils.currentLine=1048577;
 //BA.debugLineNum = 1048577;BA.debugLine="mWidth = Width";
__ref._mwidth = _width;
RDebugUtils.currentLine=1048578;
 //BA.debugLineNum = 1048578;BA.debugLine="mHeight = Max(Height, 30dip)				' limits the heig";
__ref._mheight = (int) (__c.Max(_height,__c.DipToCurrent((int) (30))));
RDebugUtils.currentLine=1048579;
 //BA.debugLineNum = 1048579;BA.debugLine="mHeight = Min(Height, 60dip)					' limits the hei";
__ref._mheight = (int) (__c.Min(_height,__c.DipToCurrent((int) (60))));
RDebugUtils.currentLine=1048580;
 //BA.debugLineNum = 1048580;BA.debugLine="mRadius = Min(Radius, Height / 2)		' limits the m";
__ref._mradius = (int) (__c.Min(_radius,_height/(double)2));
RDebugUtils.currentLine=1048581;
 //BA.debugLineNum = 1048581;BA.debugLine="mBackgroundColor = BackgroundColor";
__ref._mbackgroundcolor = _backgroundcolor;
RDebugUtils.currentLine=1048584;
 //BA.debugLineNum = 1048584;BA.debugLine="ltbPanelBack.Initialize(\"\")";
__ref._ltbpanelback.Initialize(ba,"");
RDebugUtils.currentLine=1048585;
 //BA.debugLineNum = 1048585;BA.debugLine="Parent.AddView(ltbPanelBack, Left, Top, Width, He";
_parent.AddView((android.view.View)(__ref._ltbpanelback.getObject()),_left,_top,_width,_height);
RDebugUtils.currentLine=1048587;
 //BA.debugLineNum = 1048587;BA.debugLine="InitClass		' initializes the common parts for Des";
__ref._initclass(null);
RDebugUtils.currentLine=1048588;
 //BA.debugLineNum = 1048588;BA.debugLine="End Sub";
return "";
}
public int  _getmax(b4a.limitbardemo.limitbar __ref) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "getmax"))
	return (Integer) Debug.delegate(ba, "getmax", null);
RDebugUtils.currentLine=1507328;
 //BA.debugLineNum = 1507328;BA.debugLine="Public Sub getMax As Int";
RDebugUtils.currentLine=1507329;
 //BA.debugLineNum = 1507329;BA.debugLine="Return mMaxValue";
if (true) return __ref._mmaxvalue;
RDebugUtils.currentLine=1507330;
 //BA.debugLineNum = 1507330;BA.debugLine="End Sub";
return 0;
}
public int  _getlimitleft(b4a.limitbardemo.limitbar __ref) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "getlimitleft"))
	return (Integer) Debug.delegate(ba, "getlimitleft", null);
RDebugUtils.currentLine=1638400;
 //BA.debugLineNum = 1638400;BA.debugLine="Public Sub getLimitLeft As Int";
RDebugUtils.currentLine=1638401;
 //BA.debugLineNum = 1638401;BA.debugLine="Return mLimit(0)";
if (true) return __ref._mlimit[(int) (0)];
RDebugUtils.currentLine=1638402;
 //BA.debugLineNum = 1638402;BA.debugLine="End Sub";
return 0;
}
public int  _getlimitright(b4a.limitbardemo.limitbar __ref) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "getlimitright"))
	return (Integer) Debug.delegate(ba, "getlimitright", null);
RDebugUtils.currentLine=1769472;
 //BA.debugLineNum = 1769472;BA.debugLine="Public Sub getLimitRight As Int";
RDebugUtils.currentLine=1769473;
 //BA.debugLineNum = 1769473;BA.debugLine="Return mLimit(1)";
if (true) return __ref._mlimit[(int) (1)];
RDebugUtils.currentLine=1769474;
 //BA.debugLineNum = 1769474;BA.debugLine="End Sub";
return 0;
}
public String  _setmax(b4a.limitbardemo.limitbar __ref,int _maxvalue) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "setmax"))
	return (String) Debug.delegate(ba, "setmax", new Object[] {_maxvalue});
RDebugUtils.currentLine=1441792;
 //BA.debugLineNum = 1441792;BA.debugLine="Public Sub setMax(MaxValue As Int)";
RDebugUtils.currentLine=1441793;
 //BA.debugLineNum = 1441793;BA.debugLine="mMaxValue = MaxValue";
__ref._mmaxvalue = _maxvalue;
RDebugUtils.currentLine=1441794;
 //BA.debugLineNum = 1441794;BA.debugLine="InitCursors";
__ref._initcursors(null);
RDebugUtils.currentLine=1441795;
 //BA.debugLineNum = 1441795;BA.debugLine="DrawCursors";
__ref._drawcursors(null);
RDebugUtils.currentLine=1441796;
 //BA.debugLineNum = 1441796;BA.debugLine="End Sub";
return "";
}
public String  _setlimitleft(b4a.limitbardemo.limitbar __ref,int _pos) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "setlimitleft"))
	return (String) Debug.delegate(ba, "setlimitleft", new Object[] {_pos});
RDebugUtils.currentLine=1572864;
 //BA.debugLineNum = 1572864;BA.debugLine="Public Sub setLimitLeft(Pos As Int)";
RDebugUtils.currentLine=1572866;
 //BA.debugLineNum = 1572866;BA.debugLine="mLimit(0) = Max(0, Pos)";
__ref._mlimit[(int) (0)] = (int) (__c.Max(0,_pos));
RDebugUtils.currentLine=1572867;
 //BA.debugLineNum = 1572867;BA.debugLine="InitCursors";
__ref._initcursors(null);
RDebugUtils.currentLine=1572868;
 //BA.debugLineNum = 1572868;BA.debugLine="DrawCursors";
__ref._drawcursors(null);
RDebugUtils.currentLine=1572869;
 //BA.debugLineNum = 1572869;BA.debugLine="End Sub";
return "";
}
public String  _setlimitright(b4a.limitbardemo.limitbar __ref,int _pos) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "setlimitright"))
	return (String) Debug.delegate(ba, "setlimitright", new Object[] {_pos});
RDebugUtils.currentLine=1703936;
 //BA.debugLineNum = 1703936;BA.debugLine="Public Sub setLimitRight(Pos As Int)";
RDebugUtils.currentLine=1703938;
 //BA.debugLineNum = 1703938;BA.debugLine="mLimit(1) = Min(mMaxValue, Pos)";
__ref._mlimit[(int) (1)] = (int) (__c.Min(__ref._mmaxvalue,_pos));
RDebugUtils.currentLine=1703939;
 //BA.debugLineNum = 1703939;BA.debugLine="InitCursors";
__ref._initcursors(null);
RDebugUtils.currentLine=1703940;
 //BA.debugLineNum = 1703940;BA.debugLine="DrawCursors";
__ref._drawcursors(null);
RDebugUtils.currentLine=1703941;
 //BA.debugLineNum = 1703941;BA.debugLine="End Sub";
return "";
}
public String  _setleft(b4a.limitbardemo.limitbar __ref,int _left) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "setleft"))
	return (String) Debug.delegate(ba, "setleft", new Object[] {_left});
RDebugUtils.currentLine=1835008;
 //BA.debugLineNum = 1835008;BA.debugLine="Public Sub setLeft(Left As Int)";
RDebugUtils.currentLine=1835009;
 //BA.debugLineNum = 1835009;BA.debugLine="ltbPanelBack.Left = Left";
__ref._ltbpanelback.setLeft(_left);
RDebugUtils.currentLine=1835010;
 //BA.debugLineNum = 1835010;BA.debugLine="End Sub";
return "";
}
public String  _setwidth(b4a.limitbardemo.limitbar __ref,int _width) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "setwidth"))
	return (String) Debug.delegate(ba, "setwidth", new Object[] {_width});
RDebugUtils.currentLine=2097152;
 //BA.debugLineNum = 2097152;BA.debugLine="Public Sub setWidth(Width As Int)";
RDebugUtils.currentLine=2097153;
 //BA.debugLineNum = 2097153;BA.debugLine="mWidth = Width";
__ref._mwidth = _width;
RDebugUtils.currentLine=2097154;
 //BA.debugLineNum = 2097154;BA.debugLine="ltbPanelBack.Width = mWidth";
__ref._ltbpanelback.setWidth(__ref._mwidth);
RDebugUtils.currentLine=2097155;
 //BA.debugLineNum = 2097155;BA.debugLine="ltbPanelFront.Width = mWidth";
__ref._ltbpanelfront.setWidth(__ref._mwidth);
RDebugUtils.currentLine=2097156;
 //BA.debugLineNum = 2097156;BA.debugLine="cvsPanelBack.Initialize(ltbPanelBack)";
__ref._cvspanelback.Initialize((android.view.View)(__ref._ltbpanelback.getObject()));
RDebugUtils.currentLine=2097157;
 //BA.debugLineNum = 2097157;BA.debugLine="cvsPanelFront.Initialize(ltbPanelFront)";
__ref._cvspanelfront.Initialize((android.view.View)(__ref._ltbpanelfront.getObject()));
RDebugUtils.currentLine=2097160;
 //BA.debugLineNum = 2097160;BA.debugLine="rectPanelFront.Initialize(0, 0, ltbPanelFront.Wid";
__ref._rectpanelfront.Initialize((int) (0),(int) (0),__ref._ltbpanelfront.getWidth(),__ref._ltbpanelfront.getHeight());
RDebugUtils.currentLine=2097162;
 //BA.debugLineNum = 2097162;BA.debugLine="InitCursors";
__ref._initcursors(null);
RDebugUtils.currentLine=2097163;
 //BA.debugLineNum = 2097163;BA.debugLine="DrawBackGround";
__ref._drawbackground(null);
RDebugUtils.currentLine=2097164;
 //BA.debugLineNum = 2097164;BA.debugLine="DrawCursors";
__ref._drawcursors(null);
RDebugUtils.currentLine=2097165;
 //BA.debugLineNum = 2097165;BA.debugLine="End Sub";
return "";
}
public String  _setheight(b4a.limitbardemo.limitbar __ref,int _height) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "setheight"))
	return (String) Debug.delegate(ba, "setheight", new Object[] {_height});
RDebugUtils.currentLine=2228224;
 //BA.debugLineNum = 2228224;BA.debugLine="Public Sub setHeight(Height As Int)";
RDebugUtils.currentLine=2228225;
 //BA.debugLineNum = 2228225;BA.debugLine="mHeight = Max(Height, 30dip)";
__ref._mheight = (int) (__c.Max(_height,__c.DipToCurrent((int) (30))));
RDebugUtils.currentLine=2228226;
 //BA.debugLineNum = 2228226;BA.debugLine="ltbPanelBack.Height = mHeight";
__ref._ltbpanelback.setHeight(__ref._mheight);
RDebugUtils.currentLine=2228227;
 //BA.debugLineNum = 2228227;BA.debugLine="ltbPanelFront.Height = mHeight";
__ref._ltbpanelfront.setHeight(__ref._mheight);
RDebugUtils.currentLine=2228228;
 //BA.debugLineNum = 2228228;BA.debugLine="cvsPanelBack.Initialize(ltbPanelBack)";
__ref._cvspanelback.Initialize((android.view.View)(__ref._ltbpanelback.getObject()));
RDebugUtils.currentLine=2228229;
 //BA.debugLineNum = 2228229;BA.debugLine="cvsPanelFront.Initialize(ltbPanelFront)";
__ref._cvspanelfront.Initialize((android.view.View)(__ref._ltbpanelfront.getObject()));
RDebugUtils.currentLine=2228232;
 //BA.debugLineNum = 2228232;BA.debugLine="rectPanelFront.Initialize(0, 0, mWidth, mHeight)";
__ref._rectpanelfront.Initialize((int) (0),(int) (0),__ref._mwidth,__ref._mheight);
RDebugUtils.currentLine=2228234;
 //BA.debugLineNum = 2228234;BA.debugLine="InitCursors";
__ref._initcursors(null);
RDebugUtils.currentLine=2228235;
 //BA.debugLineNum = 2228235;BA.debugLine="DrawBackGround";
__ref._drawbackground(null);
RDebugUtils.currentLine=2228236;
 //BA.debugLineNum = 2228236;BA.debugLine="DrawCursors";
__ref._drawcursors(null);
RDebugUtils.currentLine=2228237;
 //BA.debugLineNum = 2228237;BA.debugLine="End Sub";
return "";
}
public String  _setbacklinecolor(b4a.limitbardemo.limitbar __ref,int _backlinecolor) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "setbacklinecolor"))
	return (String) Debug.delegate(ba, "setbacklinecolor", new Object[] {_backlinecolor});
RDebugUtils.currentLine=2490368;
 //BA.debugLineNum = 2490368;BA.debugLine="Public Sub setBackLineColor(BackLineColor As Int)";
RDebugUtils.currentLine=2490369;
 //BA.debugLineNum = 2490369;BA.debugLine="mBackLineColor = BackLineColor";
__ref._mbacklinecolor = _backlinecolor;
RDebugUtils.currentLine=2490370;
 //BA.debugLineNum = 2490370;BA.debugLine="If ltbPanelBack.IsInitialized Then";
if (__ref._ltbpanelback.IsInitialized()) { 
RDebugUtils.currentLine=2490371;
 //BA.debugLineNum = 2490371;BA.debugLine="DrawBackGround";
__ref._drawbackground(null);
 };
RDebugUtils.currentLine=2490373;
 //BA.debugLineNum = 2490373;BA.debugLine="End Sub";
return "";
}
public String  _initclass(b4a.limitbardemo.limitbar __ref) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "initclass"))
	return (String) Debug.delegate(ba, "initclass", null);
RDebugUtils.currentLine=1114112;
 //BA.debugLineNum = 1114112;BA.debugLine="Private Sub InitClass";
RDebugUtils.currentLine=1114114;
 //BA.debugLineNum = 1114114;BA.debugLine="cdwBackground.Initialize(mBackgroundColor, mRadiu";
__ref._cdwbackground.Initialize(__ref._mbackgroundcolor,__ref._mradius);
RDebugUtils.currentLine=1114115;
 //BA.debugLineNum = 1114115;BA.debugLine="ltbPanelBack.Background = cdwBackground";
__ref._ltbpanelback.setBackground((android.graphics.drawable.Drawable)(__ref._cdwbackground.getObject()));
RDebugUtils.currentLine=1114118;
 //BA.debugLineNum = 1114118;BA.debugLine="ltbPanelFront.Initialize(\"ltbPanelFront\")";
__ref._ltbpanelfront.Initialize(ba,"ltbPanelFront");
RDebugUtils.currentLine=1114119;
 //BA.debugLineNum = 1114119;BA.debugLine="ltbPanelBack.AddView(ltbPanelFront, 0, 0, ltbPane";
__ref._ltbpanelback.AddView((android.view.View)(__ref._ltbpanelfront.getObject()),(int) (0),(int) (0),__ref._ltbpanelback.getWidth(),__ref._ltbpanelback.getHeight());
RDebugUtils.currentLine=1114122;
 //BA.debugLineNum = 1114122;BA.debugLine="rectPanelFront.Initialize(0, 0, ltbPanelFront.Wid";
__ref._rectpanelfront.Initialize((int) (0),(int) (0),__ref._ltbpanelfront.getWidth(),__ref._ltbpanelfront.getHeight());
RDebugUtils.currentLine=1114123;
 //BA.debugLineNum = 1114123;BA.debugLine="ltbPanelFront.BringToFront";
__ref._ltbpanelfront.BringToFront();
RDebugUtils.currentLine=1114126;
 //BA.debugLineNum = 1114126;BA.debugLine="cvsPanelBack.Initialize(ltbPanelBack)";
__ref._cvspanelback.Initialize((android.view.View)(__ref._ltbpanelback.getObject()));
RDebugUtils.currentLine=1114129;
 //BA.debugLineNum = 1114129;BA.debugLine="cvsPanelFront.Initialize(ltbPanelFront)";
__ref._cvspanelfront.Initialize((android.view.View)(__ref._ltbpanelfront.getObject()));
RDebugUtils.currentLine=1114132;
 //BA.debugLineNum = 1114132;BA.debugLine="setMax(mMaxValue)";
__ref._setmax(null,__ref._mmaxvalue);
RDebugUtils.currentLine=1114134;
 //BA.debugLineNum = 1114134;BA.debugLine="DrawBackGround";
__ref._drawbackground(null);
RDebugUtils.currentLine=1114135;
 //BA.debugLineNum = 1114135;BA.debugLine="End Sub";
return "";
}
public String  _class_globals(b4a.limitbardemo.limitbar __ref) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
RDebugUtils.currentLine=851968;
 //BA.debugLineNum = 851968;BA.debugLine="Sub Class_Globals";
RDebugUtils.currentLine=851969;
 //BA.debugLineNum = 851969;BA.debugLine="Private mCallback As Object				' calling module";
_mcallback = new Object();
RDebugUtils.currentLine=851970;
 //BA.debugLineNum = 851970;BA.debugLine="Private mEventName As String			' event name";
_meventname = "";
RDebugUtils.currentLine=851971;
 //BA.debugLineNum = 851971;BA.debugLine="Private mWidth, mHeight, mRadius As Int";
_mwidth = 0;
_mheight = 0;
_mradius = 0;
RDebugUtils.currentLine=851973;
 //BA.debugLineNum = 851973;BA.debugLine="Private ltbPanelBack As Panel			' the background";
_ltbpanelback = new anywheresoftware.b4a.objects.PanelWrapper();
RDebugUtils.currentLine=851974;
 //BA.debugLineNum = 851974;BA.debugLine="Private ltbPanelFront As Panel		' the foreground";
_ltbpanelfront = new anywheresoftware.b4a.objects.PanelWrapper();
RDebugUtils.currentLine=851975;
 //BA.debugLineNum = 851975;BA.debugLine="Private cvsPanelBack As Canvas		' the background";
_cvspanelback = new anywheresoftware.b4a.objects.drawable.CanvasWrapper();
RDebugUtils.currentLine=851976;
 //BA.debugLineNum = 851976;BA.debugLine="Private cvsPanelFront As Canvas		' the foreground";
_cvspanelfront = new anywheresoftware.b4a.objects.drawable.CanvasWrapper();
RDebugUtils.currentLine=851977;
 //BA.debugLineNum = 851977;BA.debugLine="Private rectPanelFront As Rect		' a rectangle for";
_rectpanelfront = new anywheresoftware.b4a.objects.drawable.CanvasWrapper.RectWrapper();
RDebugUtils.currentLine=851979;
 //BA.debugLineNum = 851979;BA.debugLine="Private mBackgroundColor As Int		' color for the";
_mbackgroundcolor = 0;
RDebugUtils.currentLine=851980;
 //BA.debugLineNum = 851980;BA.debugLine="Private cdwBackground As ColorDrawable	' backgrou";
_cdwbackground = new anywheresoftware.b4a.objects.drawable.ColorDrawable();
RDebugUtils.currentLine=851981;
 //BA.debugLineNum = 851981;BA.debugLine="Private mBackLineColor As Int			' color for the b";
_mbacklinecolor = 0;
RDebugUtils.currentLine=851982;
 //BA.debugLineNum = 851982;BA.debugLine="Private mFrontLineColor As Int		' color for the f";
_mfrontlinecolor = 0;
RDebugUtils.currentLine=851983;
 //BA.debugLineNum = 851983;BA.debugLine="Private mMargin As Int						' left and right marg";
_mmargin = 0;
RDebugUtils.currentLine=851984;
 //BA.debugLineNum = 851984;BA.debugLine="Private x0, y0, x1, y1, y2 As Int	' backline and";
_x0 = 0;
_y0 = 0;
_x1 = 0;
_y1 = 0;
_y2 = 0;
RDebugUtils.currentLine=851985;
 //BA.debugLineNum = 851985;BA.debugLine="Private mMaxValue As Int					' value of the Max p";
_mmaxvalue = 0;
RDebugUtils.currentLine=851986;
 //BA.debugLineNum = 851986;BA.debugLine="Private mScale As Double					' scale between posi";
_mscale = 0;
RDebugUtils.currentLine=851987;
 //BA.debugLineNum = 851987;BA.debugLine="Private mLimit(2) As Int					' values of the limi";
_mlimit = new int[(int) (2)];
;
RDebugUtils.currentLine=851988;
 //BA.debugLineNum = 851988;BA.debugLine="Private PositionPixels(2) As Int	' left and right";
_positionpixels = new int[(int) (2)];
;
RDebugUtils.currentLine=851989;
 //BA.debugLineNum = 851989;BA.debugLine="Private Paths(2) As Path					' two paths for the";
_paths = new anywheresoftware.b4a.objects.drawable.CanvasWrapper.PathWrapper[(int) (2)];
{
int d0 = _paths.length;
for (int i0 = 0;i0 < d0;i0++) {
_paths[i0] = new anywheresoftware.b4a.objects.drawable.CanvasWrapper.PathWrapper();
}
}
;
RDebugUtils.currentLine=851990;
 //BA.debugLineNum = 851990;BA.debugLine="Private PosIndex As Int						' current index of t";
_posindex = 0;
RDebugUtils.currentLine=851992;
 //BA.debugLineNum = 851992;BA.debugLine="End Sub";
return "";
}
public String  _designercreateview(b4a.limitbardemo.limitbar __ref,anywheresoftware.b4a.objects.PanelWrapper _base,anywheresoftware.b4a.objects.LabelWrapper _lbl,anywheresoftware.b4a.objects.collections.Map _props) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "designercreateview"))
	return (String) Debug.delegate(ba, "designercreateview", new Object[] {_base,_lbl,_props});
RDebugUtils.currentLine=983040;
 //BA.debugLineNum = 983040;BA.debugLine="Public Sub DesignerCreateView(Base As Panel, Lbl A";
RDebugUtils.currentLine=983042;
 //BA.debugLineNum = 983042;BA.debugLine="ltbPanelBack = Base";
__ref._ltbpanelback = _base;
RDebugUtils.currentLine=983045;
 //BA.debugLineNum = 983045;BA.debugLine="mWidth = Base.Width";
__ref._mwidth = _base.getWidth();
RDebugUtils.currentLine=983046;
 //BA.debugLineNum = 983046;BA.debugLine="mHeight = Base.Height";
__ref._mheight = _base.getHeight();
RDebugUtils.currentLine=983049;
 //BA.debugLineNum = 983049;BA.debugLine="mMaxValue = Props.Get(\"Max\")";
__ref._mmaxvalue = (int)(BA.ObjectToNumber(_props.Get((Object)("Max"))));
RDebugUtils.currentLine=983050;
 //BA.debugLineNum = 983050;BA.debugLine="mLimit(0) = Props.Get(\"LimitLeft\")";
__ref._mlimit[(int) (0)] = (int)(BA.ObjectToNumber(_props.Get((Object)("LimitLeft"))));
RDebugUtils.currentLine=983051;
 //BA.debugLineNum = 983051;BA.debugLine="mLimit(0) = Max(0, mLimit(0))					' we check the";
__ref._mlimit[(int) (0)] = (int) (__c.Max(0,__ref._mlimit[(int) (0)]));
RDebugUtils.currentLine=983053;
 //BA.debugLineNum = 983053;BA.debugLine="mLimit(1) = Props.Get(\"LimitRight\")";
__ref._mlimit[(int) (1)] = (int)(BA.ObjectToNumber(_props.Get((Object)("LimitRight"))));
RDebugUtils.currentLine=983054;
 //BA.debugLineNum = 983054;BA.debugLine="mLimit(1) = Min(mMaxValue, mLimit(1))	' we check";
__ref._mlimit[(int) (1)] = (int) (__c.Min(__ref._mmaxvalue,__ref._mlimit[(int) (1)]));
RDebugUtils.currentLine=983056;
 //BA.debugLineNum = 983056;BA.debugLine="mRadius = Props.Get(\"Radius\")";
__ref._mradius = (int)(BA.ObjectToNumber(_props.Get((Object)("Radius"))));
RDebugUtils.currentLine=983057;
 //BA.debugLineNum = 983057;BA.debugLine="mBackgroundColor = Props.Get(\"BackgroundColor\")";
__ref._mbackgroundcolor = (int)(BA.ObjectToNumber(_props.Get((Object)("BackgroundColor"))));
RDebugUtils.currentLine=983058;
 //BA.debugLineNum = 983058;BA.debugLine="mBackLineColor = Props.Get(\"BackLineColor\")";
__ref._mbacklinecolor = (int)(BA.ObjectToNumber(_props.Get((Object)("BackLineColor"))));
RDebugUtils.currentLine=983059;
 //BA.debugLineNum = 983059;BA.debugLine="mFrontLineColor = Props.Get(\"FrontLineColor\")";
__ref._mfrontlinecolor = (int)(BA.ObjectToNumber(_props.Get((Object)("FrontLineColor"))));
RDebugUtils.currentLine=983061;
 //BA.debugLineNum = 983061;BA.debugLine="InitClass		' initializes the common parts for Des";
__ref._initclass(null);
RDebugUtils.currentLine=983062;
 //BA.debugLineNum = 983062;BA.debugLine="End Sub";
return "";
}
public String  _drawbackground(b4a.limitbardemo.limitbar __ref) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "drawbackground"))
	return (String) Debug.delegate(ba, "drawbackground", null);
RDebugUtils.currentLine=1245184;
 //BA.debugLineNum = 1245184;BA.debugLine="Private Sub DrawBackGround";
RDebugUtils.currentLine=1245185;
 //BA.debugLineNum = 1245185;BA.debugLine="ltbPanelBack.Background = cdwBackground";
__ref._ltbpanelback.setBackground((android.graphics.drawable.Drawable)(__ref._cdwbackground.getObject()));
RDebugUtils.currentLine=1245186;
 //BA.debugLineNum = 1245186;BA.debugLine="cvsPanelBack.Initialize(ltbPanelBack)";
__ref._cvspanelback.Initialize((android.view.View)(__ref._ltbpanelback.getObject()));
RDebugUtils.currentLine=1245187;
 //BA.debugLineNum = 1245187;BA.debugLine="cvsPanelBack.DrawLine(x0, y0, x1, y0, mBackLineCo";
__ref._cvspanelback.DrawLine((float) (__ref._x0),(float) (__ref._y0),(float) (__ref._x1),(float) (__ref._y0),__ref._mbacklinecolor,(float) (__c.DipToCurrent((int) (2))));
RDebugUtils.currentLine=1245188;
 //BA.debugLineNum = 1245188;BA.debugLine="ltbPanelBack.Invalidate";
__ref._ltbpanelback.Invalidate();
RDebugUtils.currentLine=1245189;
 //BA.debugLineNum = 1245189;BA.debugLine="End Sub";
return "";
}
public String  _drawcursors(b4a.limitbardemo.limitbar __ref) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "drawcursors"))
	return (String) Debug.delegate(ba, "drawcursors", null);
RDebugUtils.currentLine=1310720;
 //BA.debugLineNum = 1310720;BA.debugLine="Private Sub DrawCursors";
RDebugUtils.currentLine=1310722;
 //BA.debugLineNum = 1310722;BA.debugLine="cvsPanelFront.DrawRect(rectPanelFront, Colors.Tra";
__ref._cvspanelfront.DrawRect((android.graphics.Rect)(__ref._rectpanelfront.getObject()),__c.Colors.Transparent,__c.True,(float) (1));
RDebugUtils.currentLine=1310725;
 //BA.debugLineNum = 1310725;BA.debugLine="Paths(0).Initialize(PositionPixels(0), y0)";
__ref._paths[(int) (0)].Initialize((float) (__ref._positionpixels[(int) (0)]),(float) (__ref._y0));
RDebugUtils.currentLine=1310726;
 //BA.debugLineNum = 1310726;BA.debugLine="Paths(0).LineTo(PositionPixels(0), y2)";
__ref._paths[(int) (0)].LineTo((float) (__ref._positionpixels[(int) (0)]),(float) (__ref._y2));
RDebugUtils.currentLine=1310727;
 //BA.debugLineNum = 1310727;BA.debugLine="Paths(0).LineTo(PositionPixels(0) - 12dip, y2)";
__ref._paths[(int) (0)].LineTo((float) (__ref._positionpixels[(int) (0)]-__c.DipToCurrent((int) (12))),(float) (__ref._y2));
RDebugUtils.currentLine=1310728;
 //BA.debugLineNum = 1310728;BA.debugLine="Paths(0).LineTo(PositionPixels(0) - 12dip, y1)";
__ref._paths[(int) (0)].LineTo((float) (__ref._positionpixels[(int) (0)]-__c.DipToCurrent((int) (12))),(float) (__ref._y1));
RDebugUtils.currentLine=1310729;
 //BA.debugLineNum = 1310729;BA.debugLine="Paths(0).LineTo(PositionPixels(0), y0)";
__ref._paths[(int) (0)].LineTo((float) (__ref._positionpixels[(int) (0)]),(float) (__ref._y0));
RDebugUtils.currentLine=1310732;
 //BA.debugLineNum = 1310732;BA.debugLine="Paths(1).Initialize(PositionPixels(1), y0)";
__ref._paths[(int) (1)].Initialize((float) (__ref._positionpixels[(int) (1)]),(float) (__ref._y0));
RDebugUtils.currentLine=1310733;
 //BA.debugLineNum = 1310733;BA.debugLine="Paths(1).LineTo(PositionPixels(1), y2)";
__ref._paths[(int) (1)].LineTo((float) (__ref._positionpixels[(int) (1)]),(float) (__ref._y2));
RDebugUtils.currentLine=1310734;
 //BA.debugLineNum = 1310734;BA.debugLine="Paths(1).LineTo(PositionPixels(1) + 12dip, y2)";
__ref._paths[(int) (1)].LineTo((float) (__ref._positionpixels[(int) (1)]+__c.DipToCurrent((int) (12))),(float) (__ref._y2));
RDebugUtils.currentLine=1310735;
 //BA.debugLineNum = 1310735;BA.debugLine="Paths(1).LineTo(PositionPixels(1) + 12dip, y1)";
__ref._paths[(int) (1)].LineTo((float) (__ref._positionpixels[(int) (1)]+__c.DipToCurrent((int) (12))),(float) (__ref._y1));
RDebugUtils.currentLine=1310736;
 //BA.debugLineNum = 1310736;BA.debugLine="Paths(1).LineTo(PositionPixels(1), y0)";
__ref._paths[(int) (1)].LineTo((float) (__ref._positionpixels[(int) (1)]),(float) (__ref._y0));
RDebugUtils.currentLine=1310739;
 //BA.debugLineNum = 1310739;BA.debugLine="cvsPanelFront.DrawPath(Paths(0), mFrontLineColor,";
__ref._cvspanelfront.DrawPath((android.graphics.Path)(__ref._paths[(int) (0)].getObject()),__ref._mfrontlinecolor,__c.True,(float) (1));
RDebugUtils.currentLine=1310740;
 //BA.debugLineNum = 1310740;BA.debugLine="cvsPanelFront.DrawPath(Paths(1), mFrontLineColor,";
__ref._cvspanelfront.DrawPath((android.graphics.Path)(__ref._paths[(int) (1)].getObject()),__ref._mfrontlinecolor,__c.True,(float) (1));
RDebugUtils.currentLine=1310741;
 //BA.debugLineNum = 1310741;BA.debugLine="cvsPanelFront.DrawLine(PositionPixels(0), y0, Pos";
__ref._cvspanelfront.DrawLine((float) (__ref._positionpixels[(int) (0)]),(float) (__ref._y0),(float) (__ref._positionpixels[(int) (1)]),(float) (__ref._y0),__ref._mfrontlinecolor,(float) (__c.DipToCurrent((int) (3))));
RDebugUtils.currentLine=1310743;
 //BA.debugLineNum = 1310743;BA.debugLine="ltbPanelFront.Invalidate";
__ref._ltbpanelfront.Invalidate();
RDebugUtils.currentLine=1310744;
 //BA.debugLineNum = 1310744;BA.debugLine="End Sub";
return "";
}
public int  _getbacklinecolor(b4a.limitbardemo.limitbar __ref) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "getbacklinecolor"))
	return (Integer) Debug.delegate(ba, "getbacklinecolor", null);
RDebugUtils.currentLine=2555904;
 //BA.debugLineNum = 2555904;BA.debugLine="Public Sub getBackLineColor As Int";
RDebugUtils.currentLine=2555905;
 //BA.debugLineNum = 2555905;BA.debugLine="Return mBackLineColor";
if (true) return __ref._mbacklinecolor;
RDebugUtils.currentLine=2555906;
 //BA.debugLineNum = 2555906;BA.debugLine="End Sub";
return 0;
}
public int  _getfrontinecolor(b4a.limitbardemo.limitbar __ref) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "getfrontinecolor"))
	return (Integer) Debug.delegate(ba, "getfrontinecolor", null);
RDebugUtils.currentLine=2686976;
 //BA.debugLineNum = 2686976;BA.debugLine="Public Sub getFrontineColor As Int";
RDebugUtils.currentLine=2686977;
 //BA.debugLineNum = 2686977;BA.debugLine="Return mFrontLineColor";
if (true) return __ref._mfrontlinecolor;
RDebugUtils.currentLine=2686978;
 //BA.debugLineNum = 2686978;BA.debugLine="End Sub";
return 0;
}
public int  _getheight(b4a.limitbardemo.limitbar __ref) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "getheight"))
	return (Integer) Debug.delegate(ba, "getheight", null);
RDebugUtils.currentLine=2293760;
 //BA.debugLineNum = 2293760;BA.debugLine="Public Sub getHeight As Int";
RDebugUtils.currentLine=2293761;
 //BA.debugLineNum = 2293761;BA.debugLine="Return ltbPanelBack.Height";
if (true) return __ref._ltbpanelback.getHeight();
RDebugUtils.currentLine=2293762;
 //BA.debugLineNum = 2293762;BA.debugLine="End Sub";
return 0;
}
public int  _getleft(b4a.limitbardemo.limitbar __ref) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "getleft"))
	return (Integer) Debug.delegate(ba, "getleft", null);
RDebugUtils.currentLine=1900544;
 //BA.debugLineNum = 1900544;BA.debugLine="Public Sub getLeft As Int";
RDebugUtils.currentLine=1900545;
 //BA.debugLineNum = 1900545;BA.debugLine="Return ltbPanelBack.Left";
if (true) return __ref._ltbpanelback.getLeft();
RDebugUtils.currentLine=1900546;
 //BA.debugLineNum = 1900546;BA.debugLine="End Sub";
return 0;
}
public int  _gettop(b4a.limitbardemo.limitbar __ref) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "gettop"))
	return (Integer) Debug.delegate(ba, "gettop", null);
RDebugUtils.currentLine=2031616;
 //BA.debugLineNum = 2031616;BA.debugLine="Public Sub getTop As Int";
RDebugUtils.currentLine=2031617;
 //BA.debugLineNum = 2031617;BA.debugLine="Return ltbPanelBack.Top";
if (true) return __ref._ltbpanelback.getTop();
RDebugUtils.currentLine=2031618;
 //BA.debugLineNum = 2031618;BA.debugLine="End Sub";
return 0;
}
public boolean  _getvisible(b4a.limitbardemo.limitbar __ref) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "getvisible"))
	return (Boolean) Debug.delegate(ba, "getvisible", null);
RDebugUtils.currentLine=2424832;
 //BA.debugLineNum = 2424832;BA.debugLine="Public Sub getVisible As Boolean";
RDebugUtils.currentLine=2424833;
 //BA.debugLineNum = 2424833;BA.debugLine="Return ltbPanelBack.Visible";
if (true) return __ref._ltbpanelback.getVisible();
RDebugUtils.currentLine=2424834;
 //BA.debugLineNum = 2424834;BA.debugLine="End Sub";
return false;
}
public int  _getwidth(b4a.limitbardemo.limitbar __ref) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "getwidth"))
	return (Integer) Debug.delegate(ba, "getwidth", null);
RDebugUtils.currentLine=2162688;
 //BA.debugLineNum = 2162688;BA.debugLine="Public Sub getWidth As Int";
RDebugUtils.currentLine=2162689;
 //BA.debugLineNum = 2162689;BA.debugLine="Return ltbPanelBack.Width";
if (true) return __ref._ltbpanelback.getWidth();
RDebugUtils.currentLine=2162690;
 //BA.debugLineNum = 2162690;BA.debugLine="End Sub";
return 0;
}
public String  _initcursors(b4a.limitbardemo.limitbar __ref) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "initcursors"))
	return (String) Debug.delegate(ba, "initcursors", null);
RDebugUtils.currentLine=1179648;
 //BA.debugLineNum = 1179648;BA.debugLine="Private Sub InitCursors";
RDebugUtils.currentLine=1179649;
 //BA.debugLineNum = 1179649;BA.debugLine="x0 = mMargin";
__ref._x0 = __ref._mmargin;
RDebugUtils.currentLine=1179650;
 //BA.debugLineNum = 1179650;BA.debugLine="x1 = mWidth - mMargin";
__ref._x1 = (int) (__ref._mwidth-__ref._mmargin);
RDebugUtils.currentLine=1179651;
 //BA.debugLineNum = 1179651;BA.debugLine="mScale = (x1 - x0) / mMaxValue";
__ref._mscale = (__ref._x1-__ref._x0)/(double)__ref._mmaxvalue;
RDebugUtils.currentLine=1179652;
 //BA.debugLineNum = 1179652;BA.debugLine="PositionPixels(0) = mLimit(0) * mScale + x0";
__ref._positionpixels[(int) (0)] = (int) (__ref._mlimit[(int) (0)]*__ref._mscale+__ref._x0);
RDebugUtils.currentLine=1179653;
 //BA.debugLineNum = 1179653;BA.debugLine="PositionPixels(1) = mLimit(1) * mScale + x0";
__ref._positionpixels[(int) (1)] = (int) (__ref._mlimit[(int) (1)]*__ref._mscale+__ref._x0);
RDebugUtils.currentLine=1179655;
 //BA.debugLineNum = 1179655;BA.debugLine="y0 = 0.2 * mHeight";
__ref._y0 = (int) (0.2*__ref._mheight);
RDebugUtils.currentLine=1179656;
 //BA.debugLineNum = 1179656;BA.debugLine="y1 = y0 + 8dip + 0.05 * mHeight";
__ref._y1 = (int) (__ref._y0+__c.DipToCurrent((int) (8))+0.05*__ref._mheight);
RDebugUtils.currentLine=1179657;
 //BA.debugLineNum = 1179657;BA.debugLine="y2 = 0.9 * mHeight";
__ref._y2 = (int) (0.9*__ref._mheight);
RDebugUtils.currentLine=1179658;
 //BA.debugLineNum = 1179658;BA.debugLine="End Sub";
return "";
}
public String  _ltbpanelfront_touch(b4a.limitbardemo.limitbar __ref,int _action,float _x,float _y) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "ltbpanelfront_touch"))
	return (String) Debug.delegate(ba, "ltbpanelfront_touch", new Object[] {_action,_x,_y});
int _val = 0;
RDebugUtils.currentLine=1376256;
 //BA.debugLineNum = 1376256;BA.debugLine="Private Sub ltbPanelFront_Touch (Action As Int, X";
RDebugUtils.currentLine=1376258;
 //BA.debugLineNum = 1376258;BA.debugLine="X = Max(x0, X)";
_x = (float) (__c.Max(__ref._x0,_x));
RDebugUtils.currentLine=1376259;
 //BA.debugLineNum = 1376259;BA.debugLine="X = Min(x1, X)";
_x = (float) (__c.Min(__ref._x1,_x));
RDebugUtils.currentLine=1376262;
 //BA.debugLineNum = 1376262;BA.debugLine="Select Action";
switch (_action) {
case 0: {
RDebugUtils.currentLine=1376264;
 //BA.debugLineNum = 1376264;BA.debugLine="If X < Abs(PositionPixels(0) + PositionPixels(1)";
if (_x<__c.Abs(__ref._positionpixels[(int) (0)]+__ref._positionpixels[(int) (1)])/(double)2) { 
RDebugUtils.currentLine=1376266;
 //BA.debugLineNum = 1376266;BA.debugLine="PosIndex = 0";
__ref._posindex = (int) (0);
 }else {
RDebugUtils.currentLine=1376269;
 //BA.debugLineNum = 1376269;BA.debugLine="PosIndex = 1";
__ref._posindex = (int) (1);
 };
RDebugUtils.currentLine=1376271;
 //BA.debugLineNum = 1376271;BA.debugLine="mLimit(PosIndex) = Floor((X - x0) / mScale + .5)";
__ref._mlimit[__ref._posindex] = (int) (__c.Floor((_x-__ref._x0)/(double)__ref._mscale+.5));
RDebugUtils.currentLine=1376272;
 //BA.debugLineNum = 1376272;BA.debugLine="PositionPixels(PosIndex) = X";
__ref._positionpixels[__ref._posindex] = (int) (_x);
RDebugUtils.currentLine=1376273;
 //BA.debugLineNum = 1376273;BA.debugLine="DrawCursors";
__ref._drawcursors(null);
 break; }
case 2: {
RDebugUtils.currentLine=1376275;
 //BA.debugLineNum = 1376275;BA.debugLine="mLimit(PosIndex) = Floor((X - x0) / mScale + .5)";
__ref._mlimit[__ref._posindex] = (int) (__c.Floor((_x-__ref._x0)/(double)__ref._mscale+.5));
RDebugUtils.currentLine=1376276;
 //BA.debugLineNum = 1376276;BA.debugLine="PositionPixels(PosIndex) = X";
__ref._positionpixels[__ref._posindex] = (int) (_x);
RDebugUtils.currentLine=1376277;
 //BA.debugLineNum = 1376277;BA.debugLine="DrawCursors";
__ref._drawcursors(null);
 break; }
case 1: {
RDebugUtils.currentLine=1376281;
 //BA.debugLineNum = 1376281;BA.debugLine="If mLimit(0) > mLimit(1) Then";
if (__ref._mlimit[(int) (0)]>__ref._mlimit[(int) (1)]) { 
RDebugUtils.currentLine=1376282;
 //BA.debugLineNum = 1376282;BA.debugLine="Private val As Int";
_val = 0;
RDebugUtils.currentLine=1376283;
 //BA.debugLineNum = 1376283;BA.debugLine="val = mLimit(0)";
_val = __ref._mlimit[(int) (0)];
RDebugUtils.currentLine=1376284;
 //BA.debugLineNum = 1376284;BA.debugLine="mLimit(0) = mLimit(1)";
__ref._mlimit[(int) (0)] = __ref._mlimit[(int) (1)];
RDebugUtils.currentLine=1376285;
 //BA.debugLineNum = 1376285;BA.debugLine="mLimit(1) = val";
__ref._mlimit[(int) (1)] = _val;
RDebugUtils.currentLine=1376286;
 //BA.debugLineNum = 1376286;BA.debugLine="PositionPixels(0) = mLimit(0) * mScale + x0";
__ref._positionpixels[(int) (0)] = (int) (__ref._mlimit[(int) (0)]*__ref._mscale+__ref._x0);
RDebugUtils.currentLine=1376287;
 //BA.debugLineNum = 1376287;BA.debugLine="PositionPixels(1) = mLimit(1) * mScale + x0";
__ref._positionpixels[(int) (1)] = (int) (__ref._mlimit[(int) (1)]*__ref._mscale+__ref._x0);
RDebugUtils.currentLine=1376288;
 //BA.debugLineNum = 1376288;BA.debugLine="DrawCursors";
__ref._drawcursors(null);
 };
 break; }
}
;
RDebugUtils.currentLine=1376293;
 //BA.debugLineNum = 1376293;BA.debugLine="If SubExists(mCallback, mEventName & \"_ValuesChan";
if (__c.SubExists(ba,__ref._mcallback,__ref._meventname+"_ValuesChanged")) { 
RDebugUtils.currentLine=1376294;
 //BA.debugLineNum = 1376294;BA.debugLine="CallSub3(mCallback, mEventName & \"_ValuesChanged";
__c.CallSubNew3(ba,__ref._mcallback,__ref._meventname+"_ValuesChanged",(Object)(__ref._mlimit[(int) (0)]),(Object)(__ref._mlimit[(int) (1)]));
 };
RDebugUtils.currentLine=1376296;
 //BA.debugLineNum = 1376296;BA.debugLine="End Sub";
return "";
}
public String  _settop(b4a.limitbardemo.limitbar __ref,int _top) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "settop"))
	return (String) Debug.delegate(ba, "settop", new Object[] {_top});
RDebugUtils.currentLine=1966080;
 //BA.debugLineNum = 1966080;BA.debugLine="Public Sub setTop(Top As Int)";
RDebugUtils.currentLine=1966081;
 //BA.debugLineNum = 1966081;BA.debugLine="ltbPanelBack.Top = Top";
__ref._ltbpanelback.setTop(_top);
RDebugUtils.currentLine=1966082;
 //BA.debugLineNum = 1966082;BA.debugLine="End Sub";
return "";
}
public String  _setvisible(b4a.limitbardemo.limitbar __ref,boolean _isvisible) throws Exception{
__ref = this;
RDebugUtils.currentModule="limitbar";
if (Debug.shouldDelegate(ba, "setvisible"))
	return (String) Debug.delegate(ba, "setvisible", new Object[] {_isvisible});
RDebugUtils.currentLine=2359296;
 //BA.debugLineNum = 2359296;BA.debugLine="Public Sub setVisible(IsVisible As Boolean)";
RDebugUtils.currentLine=2359297;
 //BA.debugLineNum = 2359297;BA.debugLine="ltbPanelBack.Visible = IsVisible";
__ref._ltbpanelback.setVisible(_isvisible);
RDebugUtils.currentLine=2359298;
 //BA.debugLineNum = 2359298;BA.debugLine="End Sub";
return "";
}
}