package SHARK2.keymon.com.mx;


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

public class preoptimizedclv 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, "SHARK2.keymon.com.mx.preoptimizedclv");
            if (htSubs == null) {
                ba.loadHtSubs(this.getClass());
                htSubs = ba.htSubs;
            }
            
        }
        if (BA.isShellModeRuntimeCheck(ba)) 
			   this.getClass().getMethod("_class_globals", SHARK2.keymon.com.mx.preoptimizedclv.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 b4a.example3.customlistview _mclv = null;
public anywheresoftware.b4a.objects.collections.List _items = null;
public anywheresoftware.b4a.objects.collections.List _panelscache = null;
public anywheresoftware.b4a.objects.B4XViewWrapper _stubpanel = null;
public boolean _horizontal = false;
public SHARK2.keymon.com.mx.b4xset[] _assigneditems = null;
public int _assigneditemsasindex = 0;
public anywheresoftware.b4j.object.JavaObject _jclv = null;
public int _extraitems = 0;
public anywheresoftware.b4a.objects.collections.List _listofitemsthatshouldbeupdated = null;
public anywheresoftware.b4a.objects.B4XViewWrapper.XUI _xui = null;
public boolean _showscrollbar = false;
public SHARK2.keymon.com.mx.b4xseekbar _b4xseekbar1 = null;
public anywheresoftware.b4a.objects.B4XViewWrapper _pnloverlay = null;
public anywheresoftware.b4a.objects.B4XViewWrapper _lblhint = null;
public int _lastuserchangeindex = 0;
public int _numberofsteps = 0;
public int _delaybeforehidingoverlay = 0;
public Object _mcallback = null;
public String _meventname = "";
public b4a.example.dateutils _dateutils = null;
public SHARK2.keymon.com.mx.main _main = null;
public SHARK2.keymon.com.mx.appupdater _appupdater = null;
public SHARK2.keymon.com.mx.mapa_cliente _mapa_cliente = null;
public SHARK2.keymon.com.mx.mapa_rutas _mapa_rutas = null;
public SHARK2.keymon.com.mx.notificationservice _notificationservice = null;
public SHARK2.keymon.com.mx.pendientes _pendientes = null;
public SHARK2.keymon.com.mx.starter _starter = null;
public SHARK2.keymon.com.mx.subs _subs = null;
public SHARK2.keymon.com.mx.tracker _tracker = null;
public SHARK2.keymon.com.mx.newinst2 _newinst2 = null;
public SHARK2.keymon.com.mx.b4xpages _b4xpages = null;
public SHARK2.keymon.com.mx.b4xcollections _b4xcollections = null;
public SHARK2.keymon.com.mx.httputils2service _httputils2service = null;
public SHARK2.keymon.com.mx.xuiviewsutils _xuiviewsutils = null;
public String  _initialize(SHARK2.keymon.com.mx.preoptimizedclv __ref,anywheresoftware.b4a.BA _ba,Object _callback,String _eventname,b4a.example3.customlistview _clv) throws Exception{
__ref = this;
innerInitialize(_ba);
RDebugUtils.currentModule="preoptimizedclv";
if (Debug.shouldDelegate(ba, "initialize", true))
	 {return ((String) Debug.delegate(ba, "initialize", new Object[] {_ba,_callback,_eventname,_clv}));}
RDebugUtils.currentLine=78905344;
 //BA.debugLineNum = 78905344;BA.debugLine="Public Sub Initialize (Callback As Object, EventNa";
RDebugUtils.currentLine=78905345;
 //BA.debugLineNum = 78905345;BA.debugLine="mCLV = CLV";
__ref._mclv /*b4a.example3.customlistview*/  = _clv;
RDebugUtils.currentLine=78905346;
 //BA.debugLineNum = 78905346;BA.debugLine="jclv = mCLV 'ignore";
__ref._jclv /*anywheresoftware.b4j.object.JavaObject*/  = (anywheresoftware.b4j.object.JavaObject) anywheresoftware.b4a.AbsObjectWrapper.ConvertToWrapper(new anywheresoftware.b4j.object.JavaObject(), (java.lang.Object)(__ref._mclv /*b4a.example3.customlistview*/ ));
RDebugUtils.currentLine=78905351;
 //BA.debugLineNum = 78905351;BA.debugLine="items = jclv.GetFieldJO(\"_items\").RunMethod(\"getO";
__ref._items /*anywheresoftware.b4a.objects.collections.List*/  = (anywheresoftware.b4a.objects.collections.List) anywheresoftware.b4a.AbsObjectWrapper.ConvertToWrapper(new anywheresoftware.b4a.objects.collections.List(), (java.util.List)(__ref._jclv /*anywheresoftware.b4j.object.JavaObject*/ .GetFieldJO("_items").RunMethod("getObject",(Object[])(__c.Null))));
RDebugUtils.currentLine=78905352;
 //BA.debugLineNum = 78905352;BA.debugLine="horizontal = jclv.GetField(\"_horizontal\")";
__ref._horizontal /*boolean*/  = BA.ObjectToBoolean(__ref._jclv /*anywheresoftware.b4j.object.JavaObject*/ .GetField("_horizontal"));
RDebugUtils.currentLine=78905354;
 //BA.debugLineNum = 78905354;BA.debugLine="PanelsCache.Initialize";
__ref._panelscache /*anywheresoftware.b4a.objects.collections.List*/ .Initialize();
RDebugUtils.currentLine=78905355;
 //BA.debugLineNum = 78905355;BA.debugLine="StubPanel = CreatePanel";
__ref._stubpanel /*anywheresoftware.b4a.objects.B4XViewWrapper*/  = __ref._createpanel /*anywheresoftware.b4a.objects.B4XViewWrapper*/ (null);
RDebugUtils.currentLine=78905356;
 //BA.debugLineNum = 78905356;BA.debugLine="StubPanel.AddView(xui.CreatePanel(\"\"), 0, 0, 10di";
__ref._stubpanel /*anywheresoftware.b4a.objects.B4XViewWrapper*/ .AddView((android.view.View)(__ref._xui /*anywheresoftware.b4a.objects.B4XViewWrapper.XUI*/ .CreatePanel(ba,"").getObject()),(int) (0),(int) (0),__c.DipToCurrent((int) (10)),__c.DipToCurrent((int) (10)));
RDebugUtils.currentLine=78905357;
 //BA.debugLineNum = 78905357;BA.debugLine="AssignedItems = Array As B4XSet(B4XCollections.Cr";
__ref._assigneditems /*SHARK2.keymon.com.mx.b4xset[]*/  = new SHARK2.keymon.com.mx.b4xset[]{_b4xcollections._createset /*SHARK2.keymon.com.mx.b4xset*/ (ba),_b4xcollections._createset /*SHARK2.keymon.com.mx.b4xset*/ (ba)};
RDebugUtils.currentLine=78905358;
 //BA.debugLineNum = 78905358;BA.debugLine="ListOfItemsThatShouldBeUpdated.Initialize";
__ref._listofitemsthatshouldbeupdated /*anywheresoftware.b4a.objects.collections.List*/ .Initialize();
RDebugUtils.currentLine=78905359;
 //BA.debugLineNum = 78905359;BA.debugLine="mCLV.AsView.LoadLayout(\"PCLVSeekBar\")";
__ref._mclv /*b4a.example3.customlistview*/ ._asview().LoadLayout("PCLVSeekBar",ba);
RDebugUtils.currentLine=78905360;
 //BA.debugLineNum = 78905360;BA.debugLine="B4XSeekBar1.Size1 = 1dip";
__ref._b4xseekbar1 /*SHARK2.keymon.com.mx.b4xseekbar*/ ._size1 /*int*/  = __c.DipToCurrent((int) (1));
RDebugUtils.currentLine=78905361;
 //BA.debugLineNum = 78905361;BA.debugLine="B4XSeekBar1.Size2 = 1dip";
__ref._b4xseekbar1 /*SHARK2.keymon.com.mx.b4xseekbar*/ ._size2 /*int*/  = __c.DipToCurrent((int) (1));
RDebugUtils.currentLine=78905362;
 //BA.debugLineNum = 78905362;BA.debugLine="B4XSeekBar1.Radius1 = 8dip";
__ref._b4xseekbar1 /*SHARK2.keymon.com.mx.b4xseekbar*/ ._radius1 /*int*/  = __c.DipToCurrent((int) (8));
RDebugUtils.currentLine=78905363;
 //BA.debugLineNum = 78905363;BA.debugLine="B4XSeekBar1.Update";
__ref._b4xseekbar1 /*SHARK2.keymon.com.mx.b4xseekbar*/ ._update /*String*/ (null);
RDebugUtils.currentLine=78905364;
 //BA.debugLineNum = 78905364;BA.debugLine="mCallback = Callback";
__ref._mcallback /*Object*/  = _callback;
RDebugUtils.currentLine=78905365;
 //BA.debugLineNum = 78905365;BA.debugLine="mEventName = EventName";
__ref._meventname /*String*/  = _eventname;
RDebugUtils.currentLine=78905366;
 //BA.debugLineNum = 78905366;BA.debugLine="End Sub";
return "";
}
public String  _commit(SHARK2.keymon.com.mx.preoptimizedclv __ref) throws Exception{
__ref = this;
RDebugUtils.currentModule="preoptimizedclv";
if (Debug.shouldDelegate(ba, "commit", true))
	 {return ((String) Debug.delegate(ba, "commit", null));}
int _dividersize = 0;
int _totalsize = 0;
int _i = 0;
b4a.example3.customlistview._clvitem _it = null;
RDebugUtils.currentLine=79036416;
 //BA.debugLineNum = 79036416;BA.debugLine="Public Sub Commit";
RDebugUtils.currentLine=79036417;
 //BA.debugLineNum = 79036417;BA.debugLine="ClearAssignedItems";
__ref._clearassigneditems /*String*/ (null);
RDebugUtils.currentLine=79036418;
 //BA.debugLineNum = 79036418;BA.debugLine="Dim DividerSize As Int = mCLV.DividerSize";
_dividersize = (int) (__ref._mclv /*b4a.example3.customlistview*/ ._getdividersize());
RDebugUtils.currentLine=79036419;
 //BA.debugLineNum = 79036419;BA.debugLine="Dim TotalSize As Int = DividerSize";
_totalsize = _dividersize;
RDebugUtils.currentLine=79036420;
 //BA.debugLineNum = 79036420;BA.debugLine="For i = 0 To items.Size - 1";
{
final int step4 = 1;
final int limit4 = (int) (__ref._items /*anywheresoftware.b4a.objects.collections.List*/ .getSize()-1);
_i = (int) (0) ;
for (;_i <= limit4 ;_i = _i + step4 ) {
RDebugUtils.currentLine=79036421;
 //BA.debugLineNum = 79036421;BA.debugLine="Dim it As CLVItem = items.Get(i)";
_it = (b4a.example3.customlistview._clvitem)(__ref._items /*anywheresoftware.b4a.objects.collections.List*/ .Get(_i));
RDebugUtils.currentLine=79036422;
 //BA.debugLineNum = 79036422;BA.debugLine="it.Offset = TotalSize";
_it.Offset = _totalsize;
RDebugUtils.currentLine=79036423;
 //BA.debugLineNum = 79036423;BA.debugLine="TotalSize = TotalSize + it.Size + DividerSize";
_totalsize = (int) (_totalsize+_it.Size+_dividersize);
 }
};
RDebugUtils.currentLine=79036425;
 //BA.debugLineNum = 79036425;BA.debugLine="If horizontal Then";
if (__ref._horizontal /*boolean*/ ) { 
RDebugUtils.currentLine=79036426;
 //BA.debugLineNum = 79036426;BA.debugLine="mCLV.sv.ScrollViewContentWidth = TotalSize";
__ref._mclv /*b4a.example3.customlistview*/ ._sv.setScrollViewContentWidth(_totalsize);
 }else {
RDebugUtils.currentLine=79036428;
 //BA.debugLineNum = 79036428;BA.debugLine="mCLV.sv.ScrollViewContentHeight = TotalSize";
__ref._mclv /*b4a.example3.customlistview*/ ._sv.setScrollViewContentHeight(_totalsize);
 };
RDebugUtils.currentLine=79036430;
 //BA.debugLineNum = 79036430;BA.debugLine="B4XSeekBar1.mBase.Visible = ShowScrollBar";
__ref._b4xseekbar1 /*SHARK2.keymon.com.mx.b4xseekbar*/ ._mbase /*anywheresoftware.b4a.objects.B4XViewWrapper*/ .setVisible(__ref._showscrollbar /*boolean*/ );
RDebugUtils.currentLine=79036431;
 //BA.debugLineNum = 79036431;BA.debugLine="If ShowScrollBar Then";
if (__ref._showscrollbar /*boolean*/ ) { 
RDebugUtils.currentLine=79036432;
 //BA.debugLineNum = 79036432;BA.debugLine="B4XSeekBar1.MaxValue = items.Size";
__ref._b4xseekbar1 /*SHARK2.keymon.com.mx.b4xseekbar*/ ._maxvalue /*int*/  = __ref._items /*anywheresoftware.b4a.objects.collections.List*/ .getSize();
RDebugUtils.currentLine=79036433;
 //BA.debugLineNum = 79036433;BA.debugLine="B4XSeekBar1.Interval = items.Size / NumberOfStep";
__ref._b4xseekbar1 /*SHARK2.keymon.com.mx.b4xseekbar*/ ._interval /*int*/  = (int) (__ref._items /*anywheresoftware.b4a.objects.collections.List*/ .getSize()/(double)__ref._numberofsteps /*int*/ );
 };
RDebugUtils.currentLine=79036435;
 //BA.debugLineNum = 79036435;BA.debugLine="RaiseVisibleRangeEvent";
__ref._raisevisiblerangeevent /*String*/ (null);
RDebugUtils.currentLine=79036437;
 //BA.debugLineNum = 79036437;BA.debugLine="End Sub";
return "";
}
public String  _additem(SHARK2.keymon.com.mx.preoptimizedclv __ref,int _size,int _clr,Object _value) throws Exception{
__ref = this;
RDebugUtils.currentModule="preoptimizedclv";
if (Debug.shouldDelegate(ba, "additem", true))
	 {return ((String) Debug.delegate(ba, "additem", new Object[] {_size,_clr,_value}));}
b4a.example3.customlistview._clvitem _newitem = null;
RDebugUtils.currentLine=78970880;
 //BA.debugLineNum = 78970880;BA.debugLine="Public Sub AddItem (Size As Int, Clr As Int, Value";
RDebugUtils.currentLine=78970881;
 //BA.debugLineNum = 78970881;BA.debugLine="Dim NewItem As CLVItem";
_newitem = new b4a.example3.customlistview._clvitem();
RDebugUtils.currentLine=78970882;
 //BA.debugLineNum = 78970882;BA.debugLine="NewItem.Color = Clr";
_newitem.Color = _clr;
RDebugUtils.currentLine=78970883;
 //BA.debugLineNum = 78970883;BA.debugLine="NewItem.Panel = StubPanel";
_newitem.Panel = __ref._stubpanel /*anywheresoftware.b4a.objects.B4XViewWrapper*/ ;
RDebugUtils.currentLine=78970884;
 //BA.debugLineNum = 78970884;BA.debugLine="NewItem.Value = Value";
_newitem.Value = _value;
RDebugUtils.currentLine=78970885;
 //BA.debugLineNum = 78970885;BA.debugLine="NewItem.Size = Size";
_newitem.Size = _size;
RDebugUtils.currentLine=78970886;
 //BA.debugLineNum = 78970886;BA.debugLine="items.Add(NewItem)";
__ref._items /*anywheresoftware.b4a.objects.collections.List*/ .Add((Object)(_newitem));
RDebugUtils.currentLine=78970887;
 //BA.debugLineNum = 78970887;BA.debugLine="End Sub";
return "";
}
public void  _b4xseekbar1_touchstatechanged(SHARK2.keymon.com.mx.preoptimizedclv __ref,boolean _pressed) throws Exception{
RDebugUtils.currentModule="preoptimizedclv";
if (Debug.shouldDelegate(ba, "b4xseekbar1_touchstatechanged", true))
	 {Debug.delegate(ba, "b4xseekbar1_touchstatechanged", new Object[] {_pressed}); return;}
ResumableSub_B4XSeekBar1_TouchStateChanged rsub = new ResumableSub_B4XSeekBar1_TouchStateChanged(this,__ref,_pressed);
rsub.resume(ba, null);
}
public static class ResumableSub_B4XSeekBar1_TouchStateChanged extends BA.ResumableSub {
public ResumableSub_B4XSeekBar1_TouchStateChanged(SHARK2.keymon.com.mx.preoptimizedclv parent,SHARK2.keymon.com.mx.preoptimizedclv __ref,boolean _pressed) {
this.parent = parent;
this.__ref = __ref;
this._pressed = _pressed;
this.__ref = parent;
}
SHARK2.keymon.com.mx.preoptimizedclv __ref;
SHARK2.keymon.com.mx.preoptimizedclv parent;
boolean _pressed;
anywheresoftware.b4j.object.JavaObject _jo = null;

@Override
public void resume(BA ba, Object[] result) throws Exception{
RDebugUtils.currentModule="preoptimizedclv";

    while (true) {
        switch (state) {
            case -1:
return;

case 0:
//C
this.state = 1;
RDebugUtils.currentLine=79560705;
 //BA.debugLineNum = 79560705;BA.debugLine="If Pressed = False Then";
if (true) break;

case 1:
//if
this.state = 6;
if (_pressed==parent.__c.False) { 
this.state = 3;
}else {
this.state = 5;
}if (true) break;

case 3:
//C
this.state = 6;
RDebugUtils.currentLine=79560706;
 //BA.debugLineNum = 79560706;BA.debugLine="mCLV.JumpToItem(LastUserChangeIndex)";
__ref._mclv /*b4a.example3.customlistview*/ ._jumptoitem(__ref._lastuserchangeindex /*int*/ );
RDebugUtils.currentLine=79560707;
 //BA.debugLineNum = 79560707;BA.debugLine="Sleep(DelayBeforeHidingOverlay)";
parent.__c.Sleep(ba,new anywheresoftware.b4a.shell.DebugResumableSub.DelegatableResumableSub(this, "preoptimizedclv", "b4xseekbar1_touchstatechanged"),__ref._delaybeforehidingoverlay /*int*/ );
this.state = 7;
return;
case 7:
//C
this.state = 6;
;
RDebugUtils.currentLine=79560708;
 //BA.debugLineNum = 79560708;BA.debugLine="pnlOverlay.Visible = False";
__ref._pnloverlay /*anywheresoftware.b4a.objects.B4XViewWrapper*/ .setVisible(parent.__c.False);
 if (true) break;

case 5:
//C
this.state = 6;
RDebugUtils.currentLine=79560710;
 //BA.debugLineNum = 79560710;BA.debugLine="pnlOverlay.Visible = True";
__ref._pnloverlay /*anywheresoftware.b4a.objects.B4XViewWrapper*/ .setVisible(parent.__c.True);
RDebugUtils.currentLine=79560712;
 //BA.debugLineNum = 79560712;BA.debugLine="Dim jo As JavaObject = mCLV.sv";
_jo = new anywheresoftware.b4j.object.JavaObject();
_jo = (anywheresoftware.b4j.object.JavaObject) anywheresoftware.b4a.AbsObjectWrapper.ConvertToWrapper(new anywheresoftware.b4j.object.JavaObject(), (java.lang.Object)(__ref._mclv /*b4a.example3.customlistview*/ ._sv.getObject()));
RDebugUtils.currentLine=79560713;
 //BA.debugLineNum = 79560713;BA.debugLine="jo.RunMethod(\"fling\", Array(0))";
_jo.RunMethod("fling",new Object[]{(Object)(0)});
 if (true) break;

case 6:
//C
this.state = -1;
;
RDebugUtils.currentLine=79560716;
 //BA.debugLineNum = 79560716;BA.debugLine="End Sub";
if (true) break;

            }
        }
    }
}
public String  _b4xseekbar1_valuechanged(SHARK2.keymon.com.mx.preoptimizedclv __ref,int _value) throws Exception{
__ref = this;
RDebugUtils.currentModule="preoptimizedclv";
if (Debug.shouldDelegate(ba, "b4xseekbar1_valuechanged", true))
	 {return ((String) Debug.delegate(ba, "b4xseekbar1_valuechanged", new Object[] {_value}));}
Object _t = null;
RDebugUtils.currentLine=79626240;
 //BA.debugLineNum = 79626240;BA.debugLine="Sub B4XSeekBar1_ValueChanged (Value As Int)";
RDebugUtils.currentLine=79626241;
 //BA.debugLineNum = 79626241;BA.debugLine="LastUserChangeIndex = Max(0, items.Size - 1 - Val";
__ref._lastuserchangeindex /*int*/  = (int) (__c.Max(0,__ref._items /*anywheresoftware.b4a.objects.collections.List*/ .getSize()-1-_value));
RDebugUtils.currentLine=79626242;
 //BA.debugLineNum = 79626242;BA.debugLine="If LastUserChangeIndex < B4XSeekBar1.Interval The";
if (__ref._lastuserchangeindex /*int*/ <__ref._b4xseekbar1 /*SHARK2.keymon.com.mx.b4xseekbar*/ ._interval /*int*/ ) { 
__ref._lastuserchangeindex /*int*/  = (int) (0);};
RDebugUtils.currentLine=79626243;
 //BA.debugLineNum = 79626243;BA.debugLine="lblHint.Text = \"\"";
__ref._lblhint /*anywheresoftware.b4a.objects.B4XViewWrapper*/ .setText(BA.ObjectToCharSequence(""));
RDebugUtils.currentLine=79626244;
 //BA.debugLineNum = 79626244;BA.debugLine="If xui.SubExists(mCallback, mEventName & \"_HintRe";
if (__ref._xui /*anywheresoftware.b4a.objects.B4XViewWrapper.XUI*/ .SubExists(ba,__ref._mcallback /*Object*/ ,__ref._meventname /*String*/ +"_HintRequested",(int) (1))) { 
RDebugUtils.currentLine=79626245;
 //BA.debugLineNum = 79626245;BA.debugLine="Dim t As Object = CallSub2(mCallback, mEventName";
_t = __c.CallSubNew2(ba,__ref._mcallback /*Object*/ ,__ref._meventname /*String*/ +"_HintRequested",(Object)(__ref._lastuserchangeindex /*int*/ ));
RDebugUtils.currentLine=79626246;
 //BA.debugLineNum = 79626246;BA.debugLine="If t <> Null Then";
if (_t!= null) { 
RDebugUtils.currentLine=79626247;
 //BA.debugLineNum = 79626247;BA.debugLine="InternalSetTextOrCSBuilderToLabel(lblHint, t)";
__ref._internalsettextorcsbuildertolabel /*String*/ (null,__ref._lblhint /*anywheresoftware.b4a.objects.B4XViewWrapper*/ ,_t);
 };
 };
RDebugUtils.currentLine=79626250;
 //BA.debugLineNum = 79626250;BA.debugLine="End Sub";
return "";
}
public String  _internalsettextorcsbuildertolabel(SHARK2.keymon.com.mx.preoptimizedclv __ref,anywheresoftware.b4a.objects.B4XViewWrapper _xlbl,Object _text) throws Exception{
__ref = this;
RDebugUtils.currentModule="preoptimizedclv";
if (Debug.shouldDelegate(ba, "internalsettextorcsbuildertolabel", true))
	 {return ((String) Debug.delegate(ba, "internalsettextorcsbuildertolabel", new Object[] {_xlbl,_text}));}
RDebugUtils.currentLine=79691776;
 //BA.debugLineNum = 79691776;BA.debugLine="Private Sub InternalSetTextOrCSBuilderToLabel(xlbl";
RDebugUtils.currentLine=79691778;
 //BA.debugLineNum = 79691778;BA.debugLine="xlbl.Text = Text";
_xlbl.setText(BA.ObjectToCharSequence(_text));
RDebugUtils.currentLine=79691788;
 //BA.debugLineNum = 79691788;BA.debugLine="End Sub";
return "";
}
public String  _class_globals(SHARK2.keymon.com.mx.preoptimizedclv __ref) throws Exception{
__ref = this;
RDebugUtils.currentModule="preoptimizedclv";
RDebugUtils.currentLine=78839808;
 //BA.debugLineNum = 78839808;BA.debugLine="Sub Class_Globals";
RDebugUtils.currentLine=78839809;
 //BA.debugLineNum = 78839809;BA.debugLine="Private mCLV As CustomListView";
_mclv = new b4a.example3.customlistview();
RDebugUtils.currentLine=78839810;
 //BA.debugLineNum = 78839810;BA.debugLine="Private items As List";
_items = new anywheresoftware.b4a.objects.collections.List();
RDebugUtils.currentLine=78839811;
 //BA.debugLineNum = 78839811;BA.debugLine="Private PanelsCache As List";
_panelscache = new anywheresoftware.b4a.objects.collections.List();
RDebugUtils.currentLine=78839812;
 //BA.debugLineNum = 78839812;BA.debugLine="Private StubPanel As B4XView";
_stubpanel = new anywheresoftware.b4a.objects.B4XViewWrapper();
RDebugUtils.currentLine=78839813;
 //BA.debugLineNum = 78839813;BA.debugLine="Private horizontal As Boolean";
_horizontal = false;
RDebugUtils.currentLine=78839814;
 //BA.debugLineNum = 78839814;BA.debugLine="Private AssignedItems() As B4XSet";
_assigneditems = new SHARK2.keymon.com.mx.b4xset[(int) (0)];
{
int d0 = _assigneditems.length;
for (int i0 = 0;i0 < d0;i0++) {
_assigneditems[i0] = new SHARK2.keymon.com.mx.b4xset();
}
}
;
RDebugUtils.currentLine=78839815;
 //BA.debugLineNum = 78839815;BA.debugLine="Private AssignedItemsAsIndex As Int";
_assigneditemsasindex = 0;
RDebugUtils.currentLine=78839819;
 //BA.debugLineNum = 78839819;BA.debugLine="Private jclv As JavaObject";
_jclv = new anywheresoftware.b4j.object.JavaObject();
RDebugUtils.currentLine=78839821;
 //BA.debugLineNum = 78839821;BA.debugLine="Public ExtraItems As Int = 3";
_extraitems = (int) (3);
RDebugUtils.currentLine=78839822;
 //BA.debugLineNum = 78839822;BA.debugLine="Private ListOfItemsThatShouldBeUpdated As List";
_listofitemsthatshouldbeupdated = new anywheresoftware.b4a.objects.collections.List();
RDebugUtils.currentLine=78839823;
 //BA.debugLineNum = 78839823;BA.debugLine="Private xui As XUI";
_xui = new anywheresoftware.b4a.objects.B4XViewWrapper.XUI();
RDebugUtils.currentLine=78839824;
 //BA.debugLineNum = 78839824;BA.debugLine="Public ShowScrollBar As Boolean = True";
_showscrollbar = __c.True;
RDebugUtils.currentLine=78839825;
 //BA.debugLineNum = 78839825;BA.debugLine="Public B4XSeekBar1 As B4XSeekBar";
_b4xseekbar1 = new SHARK2.keymon.com.mx.b4xseekbar();
RDebugUtils.currentLine=78839826;
 //BA.debugLineNum = 78839826;BA.debugLine="Public pnlOverlay As B4XView";
_pnloverlay = new anywheresoftware.b4a.objects.B4XViewWrapper();
RDebugUtils.currentLine=78839827;
 //BA.debugLineNum = 78839827;BA.debugLine="Public lblHint As B4XView";
_lblhint = new anywheresoftware.b4a.objects.B4XViewWrapper();
RDebugUtils.currentLine=78839828;
 //BA.debugLineNum = 78839828;BA.debugLine="Private LastUserChangeIndex As Int";
_lastuserchangeindex = 0;
RDebugUtils.currentLine=78839829;
 //BA.debugLineNum = 78839829;BA.debugLine="Public NumberOfSteps As Int = 20";
_numberofsteps = (int) (20);
RDebugUtils.currentLine=78839830;
 //BA.debugLineNum = 78839830;BA.debugLine="Public DelayBeforeHidingOverlay As Int = 50";
_delaybeforehidingoverlay = (int) (50);
RDebugUtils.currentLine=78839831;
 //BA.debugLineNum = 78839831;BA.debugLine="Private mCallback As Object";
_mcallback = new Object();
RDebugUtils.currentLine=78839832;
 //BA.debugLineNum = 78839832;BA.debugLine="Private mEventName As String";
_meventname = "";
RDebugUtils.currentLine=78839833;
 //BA.debugLineNum = 78839833;BA.debugLine="End Sub";
return "";
}
public String  _clearassigneditems(SHARK2.keymon.com.mx.preoptimizedclv __ref) throws Exception{
__ref = this;
RDebugUtils.currentModule="preoptimizedclv";
if (Debug.shouldDelegate(ba, "clearassigneditems", true))
	 {return ((String) Debug.delegate(ba, "clearassigneditems", null));}
SHARK2.keymon.com.mx.b4xset _s = null;
RDebugUtils.currentLine=79429632;
 //BA.debugLineNum = 79429632;BA.debugLine="Private Sub ClearAssignedItems";
RDebugUtils.currentLine=79429633;
 //BA.debugLineNum = 79429633;BA.debugLine="For Each s As B4XSet In AssignedItems";
{
final SHARK2.keymon.com.mx.b4xset[] group1 = __ref._assigneditems /*SHARK2.keymon.com.mx.b4xset[]*/ ;
final int groupLen1 = group1.length
;int index1 = 0;
;
for (; index1 < groupLen1;index1++){
_s = group1[index1];
RDebugUtils.currentLine=79429634;
 //BA.debugLineNum = 79429634;BA.debugLine="s.Clear";
_s._clear /*String*/ (null);
 }
};
RDebugUtils.currentLine=79429636;
 //BA.debugLineNum = 79429636;BA.debugLine="End Sub";
return "";
}
public String  _raisevisiblerangeevent(SHARK2.keymon.com.mx.preoptimizedclv __ref) throws Exception{
__ref = this;
RDebugUtils.currentModule="preoptimizedclv";
if (Debug.shouldDelegate(ba, "raisevisiblerangeevent", true))
	 {return ((String) Debug.delegate(ba, "raisevisiblerangeevent", null));}
RDebugUtils.currentLine=79101952;
 //BA.debugLineNum = 79101952;BA.debugLine="Private Sub RaiseVisibleRangeEvent";
RDebugUtils.currentLine=79101953;
 //BA.debugLineNum = 79101953;BA.debugLine="jclv.RunMethod(\"_resetvisibles\", Null)";
__ref._jclv /*anywheresoftware.b4j.object.JavaObject*/ .RunMethod("_resetvisibles",(Object[])(__c.Null));
RDebugUtils.currentLine=79101954;
 //BA.debugLineNum = 79101954;BA.debugLine="jclv.RunMethod(\"_updatevisiblerange\", Null)";
__ref._jclv /*anywheresoftware.b4j.object.JavaObject*/ .RunMethod("_updatevisiblerange",(Object[])(__c.Null));
RDebugUtils.currentLine=79101955;
 //BA.debugLineNum = 79101955;BA.debugLine="End Sub";
return "";
}
public anywheresoftware.b4a.objects.B4XViewWrapper  _createpanel(SHARK2.keymon.com.mx.preoptimizedclv __ref) throws Exception{
__ref = this;
RDebugUtils.currentModule="preoptimizedclv";
if (Debug.shouldDelegate(ba, "createpanel", true))
	 {return ((anywheresoftware.b4a.objects.B4XViewWrapper) Debug.delegate(ba, "createpanel", null));}
RDebugUtils.currentLine=79167488;
 //BA.debugLineNum = 79167488;BA.debugLine="Private Sub CreatePanel As B4XView";
RDebugUtils.currentLine=79167492;
 //BA.debugLineNum = 79167492;BA.debugLine="Return jclv.RunMethodJO(\"_createpanel\", Array(\"Pa";
if (true) return (anywheresoftware.b4a.objects.B4XViewWrapper) anywheresoftware.b4a.AbsObjectWrapper.ConvertToWrapper(new anywheresoftware.b4a.objects.B4XViewWrapper(), (java.lang.Object)(__ref._jclv /*anywheresoftware.b4j.object.JavaObject*/ .RunMethodJO("_createpanel",new Object[]{(Object)("Panel")}).RunMethod("getObject",(Object[])(__c.Null))));
RDebugUtils.currentLine=79167494;
 //BA.debugLineNum = 79167494;BA.debugLine="End Sub";
return null;
}
public anywheresoftware.b4a.objects.B4XViewWrapper  _getpanel(SHARK2.keymon.com.mx.preoptimizedclv __ref) throws Exception{
__ref = this;
RDebugUtils.currentModule="preoptimizedclv";
if (Debug.shouldDelegate(ba, "getpanel", true))
	 {return ((anywheresoftware.b4a.objects.B4XViewWrapper) Debug.delegate(ba, "getpanel", null));}
anywheresoftware.b4a.objects.B4XViewWrapper _p = null;
RDebugUtils.currentLine=79364096;
 //BA.debugLineNum = 79364096;BA.debugLine="Private Sub GetPanel As B4XView";
RDebugUtils.currentLine=79364097;
 //BA.debugLineNum = 79364097;BA.debugLine="If PanelsCache.Size = 0 Then Return CreatePanel";
if (__ref._panelscache /*anywheresoftware.b4a.objects.collections.List*/ .getSize()==0) { 
if (true) return __ref._createpanel /*anywheresoftware.b4a.objects.B4XViewWrapper*/ (null);};
RDebugUtils.currentLine=79364098;
 //BA.debugLineNum = 79364098;BA.debugLine="Dim p As B4XView = PanelsCache.Get(PanelsCache.Si";
_p = new anywheresoftware.b4a.objects.B4XViewWrapper();
_p = (anywheresoftware.b4a.objects.B4XViewWrapper) anywheresoftware.b4a.AbsObjectWrapper.ConvertToWrapper(new anywheresoftware.b4a.objects.B4XViewWrapper(), (java.lang.Object)(__ref._panelscache /*anywheresoftware.b4a.objects.collections.List*/ .Get((int) (__ref._panelscache /*anywheresoftware.b4a.objects.collections.List*/ .getSize()-1))));
RDebugUtils.currentLine=79364099;
 //BA.debugLineNum = 79364099;BA.debugLine="PanelsCache.RemoveAt(PanelsCache.Size - 1)";
__ref._panelscache /*anywheresoftware.b4a.objects.collections.List*/ .RemoveAt((int) (__ref._panelscache /*anywheresoftware.b4a.objects.collections.List*/ .getSize()-1));
RDebugUtils.currentLine=79364100;
 //BA.debugLineNum = 79364100;BA.debugLine="Return p";
if (true) return _p;
RDebugUtils.currentLine=79364101;
 //BA.debugLineNum = 79364101;BA.debugLine="End Sub";
return null;
}
public String  _handlescrollbar(SHARK2.keymon.com.mx.preoptimizedclv __ref,int _firstvisible) throws Exception{
__ref = this;
RDebugUtils.currentModule="preoptimizedclv";
if (Debug.shouldDelegate(ba, "handlescrollbar", true))
	 {return ((String) Debug.delegate(ba, "handlescrollbar", new Object[] {_firstvisible}));}
RDebugUtils.currentLine=79298560;
 //BA.debugLineNum = 79298560;BA.debugLine="Private Sub HandleScrollBar (FirstVisible As Int)";
RDebugUtils.currentLine=79298561;
 //BA.debugLineNum = 79298561;BA.debugLine="If ShowScrollBar = False Then Return";
if (__ref._showscrollbar /*boolean*/ ==__c.False) { 
if (true) return "";};
RDebugUtils.currentLine=79298562;
 //BA.debugLineNum = 79298562;BA.debugLine="B4XSeekBar1.Value = items.Size - FirstVisible";
__ref._b4xseekbar1 /*SHARK2.keymon.com.mx.b4xseekbar*/ ._setvalue /*int*/ (null,(int) (__ref._items /*anywheresoftware.b4a.objects.collections.List*/ .getSize()-_firstvisible));
RDebugUtils.currentLine=79298563;
 //BA.debugLineNum = 79298563;BA.debugLine="End Sub";
return "";
}
public void  _listchangedexternally(SHARK2.keymon.com.mx.preoptimizedclv __ref) throws Exception{
RDebugUtils.currentModule="preoptimizedclv";
if (Debug.shouldDelegate(ba, "listchangedexternally", true))
	 {Debug.delegate(ba, "listchangedexternally", null); return;}
ResumableSub_ListChangedExternally rsub = new ResumableSub_ListChangedExternally(this,__ref);
rsub.resume(ba, null);
}
public static class ResumableSub_ListChangedExternally extends BA.ResumableSub {
public ResumableSub_ListChangedExternally(SHARK2.keymon.com.mx.preoptimizedclv parent,SHARK2.keymon.com.mx.preoptimizedclv __ref) {
this.parent = parent;
this.__ref = __ref;
this.__ref = parent;
}
SHARK2.keymon.com.mx.preoptimizedclv __ref;
SHARK2.keymon.com.mx.preoptimizedclv parent;

@Override
public void resume(BA ba, Object[] result) throws Exception{
RDebugUtils.currentModule="preoptimizedclv";

    while (true) {
        switch (state) {
            case -1:
return;

case 0:
//C
this.state = -1;
RDebugUtils.currentLine=79495169;
 //BA.debugLineNum = 79495169;BA.debugLine="ClearAssignedItems";
__ref._clearassigneditems /*String*/ (null);
RDebugUtils.currentLine=79495170;
 //BA.debugLineNum = 79495170;BA.debugLine="Sleep(0)";
parent.__c.Sleep(ba,new anywheresoftware.b4a.shell.DebugResumableSub.DelegatableResumableSub(this, "preoptimizedclv", "listchangedexternally"),(int) (0));
this.state = 1;
return;
case 1:
//C
this.state = -1;
;
RDebugUtils.currentLine=79495171;
 //BA.debugLineNum = 79495171;BA.debugLine="RaiseVisibleRangeEvent";
__ref._raisevisiblerangeevent /*String*/ (null);
RDebugUtils.currentLine=79495172;
 //BA.debugLineNum = 79495172;BA.debugLine="End Sub";
if (true) break;

            }
        }
    }
}
public anywheresoftware.b4a.objects.collections.List  _visiblerangechanged(SHARK2.keymon.com.mx.preoptimizedclv __ref,int _firstindex,int _lastindex) throws Exception{
__ref = this;
RDebugUtils.currentModule="preoptimizedclv";
if (Debug.shouldDelegate(ba, "visiblerangechanged", true))
	 {return ((anywheresoftware.b4a.objects.collections.List) Debug.delegate(ba, "visiblerangechanged", new Object[] {_firstindex,_lastindex}));}
int _fromindex = 0;
int _toindex = 0;
SHARK2.keymon.com.mx.b4xset _prevset = null;
SHARK2.keymon.com.mx.b4xset _nextset = null;
int _i = 0;
b4a.example3.customlistview._clvitem _it = null;
anywheresoftware.b4a.objects.B4XViewWrapper _pnl = null;
RDebugUtils.currentLine=79233024;
 //BA.debugLineNum = 79233024;BA.debugLine="Public Sub VisibleRangeChanged (FirstIndex As Int,";
RDebugUtils.currentLine=79233025;
 //BA.debugLineNum = 79233025;BA.debugLine="Dim FromIndex As Int = Max(0, FirstIndex - ExtraI";
_fromindex = (int) (__c.Max(0,_firstindex-__ref._extraitems /*int*/ ));
RDebugUtils.currentLine=79233026;
 //BA.debugLineNum = 79233026;BA.debugLine="Dim ToIndex As Int = Min(mCLV.Size - 1, LastIndex";
_toindex = (int) (__c.Min(__ref._mclv /*b4a.example3.customlistview*/ ._getsize()-1,_lastindex+__ref._extraitems /*int*/ ));
RDebugUtils.currentLine=79233027;
 //BA.debugLineNum = 79233027;BA.debugLine="Dim PrevSet As B4XSet = AssignedItems(AssignedIte";
_prevset = __ref._assigneditems /*SHARK2.keymon.com.mx.b4xset[]*/ [__ref._assigneditemsasindex /*int*/ ];
RDebugUtils.currentLine=79233028;
 //BA.debugLineNum = 79233028;BA.debugLine="AssignedItemsAsIndex = (AssignedItemsAsIndex + 1)";
__ref._assigneditemsasindex /*int*/  = (int) ((__ref._assigneditemsasindex /*int*/ +1)%2);
RDebugUtils.currentLine=79233029;
 //BA.debugLineNum = 79233029;BA.debugLine="Dim NextSet As B4XSet = AssignedItems(AssignedIte";
_nextset = __ref._assigneditems /*SHARK2.keymon.com.mx.b4xset[]*/ [__ref._assigneditemsasindex /*int*/ ];
RDebugUtils.currentLine=79233030;
 //BA.debugLineNum = 79233030;BA.debugLine="NextSet.Clear";
_nextset._clear /*String*/ (null);
RDebugUtils.currentLine=79233031;
 //BA.debugLineNum = 79233031;BA.debugLine="ListOfItemsThatShouldBeUpdated.Initialize";
__ref._listofitemsthatshouldbeupdated /*anywheresoftware.b4a.objects.collections.List*/ .Initialize();
RDebugUtils.currentLine=79233032;
 //BA.debugLineNum = 79233032;BA.debugLine="For i = FromIndex To ToIndex";
{
final int step8 = 1;
final int limit8 = _toindex;
_i = _fromindex ;
for (;_i <= limit8 ;_i = _i + step8 ) {
RDebugUtils.currentLine=79233033;
 //BA.debugLineNum = 79233033;BA.debugLine="Dim it As CLVItem = items.Get(i)";
_it = (b4a.example3.customlistview._clvitem)(__ref._items /*anywheresoftware.b4a.objects.collections.List*/ .Get(_i));
RDebugUtils.currentLine=79233034;
 //BA.debugLineNum = 79233034;BA.debugLine="If it.Panel = StubPanel Then";
if ((_it.Panel).equals(__ref._stubpanel /*anywheresoftware.b4a.objects.B4XViewWrapper*/ )) { 
RDebugUtils.currentLine=79233035;
 //BA.debugLineNum = 79233035;BA.debugLine="it.Panel = GetPanel";
_it.Panel = __ref._getpanel /*anywheresoftware.b4a.objects.B4XViewWrapper*/ (null);
RDebugUtils.currentLine=79233036;
 //BA.debugLineNum = 79233036;BA.debugLine="it.Panel.Tag = i";
_it.Panel.setTag((Object)(_i));
RDebugUtils.currentLine=79233037;
 //BA.debugLineNum = 79233037;BA.debugLine="it.Panel.Color = it.Color";
_it.Panel.setColor(_it.Color);
RDebugUtils.currentLine=79233038;
 //BA.debugLineNum = 79233038;BA.debugLine="If horizontal Then";
if (__ref._horizontal /*boolean*/ ) { 
RDebugUtils.currentLine=79233039;
 //BA.debugLineNum = 79233039;BA.debugLine="mCLV.sv.ScrollViewInnerPanel.AddView(it.Panel,";
__ref._mclv /*b4a.example3.customlistview*/ ._sv.getScrollViewInnerPanel().AddView((android.view.View)(_it.Panel.getObject()),_it.Offset,(int) (0),_it.Size,__ref._mclv /*b4a.example3.customlistview*/ ._sv.getHeight());
 }else {
RDebugUtils.currentLine=79233041;
 //BA.debugLineNum = 79233041;BA.debugLine="mCLV.sv.ScrollViewInnerPanel.AddView(it.Panel,";
__ref._mclv /*b4a.example3.customlistview*/ ._sv.getScrollViewInnerPanel().AddView((android.view.View)(_it.Panel.getObject()),(int) (0),_it.Offset,__ref._mclv /*b4a.example3.customlistview*/ ._sv.getWidth(),_it.Size);
 };
RDebugUtils.currentLine=79233043;
 //BA.debugLineNum = 79233043;BA.debugLine="NextSet.Add(it.Panel)";
_nextset._add /*String*/ (null,(Object)(_it.Panel.getObject()));
RDebugUtils.currentLine=79233044;
 //BA.debugLineNum = 79233044;BA.debugLine="ListOfItemsThatShouldBeUpdated.Add(i)";
__ref._listofitemsthatshouldbeupdated /*anywheresoftware.b4a.objects.collections.List*/ .Add((Object)(_i));
 }else 
{RDebugUtils.currentLine=79233045;
 //BA.debugLineNum = 79233045;BA.debugLine="Else if PrevSet.Contains(it.Panel) Then";
if (_prevset._contains /*boolean*/ (null,(Object)(_it.Panel.getObject()))) { 
RDebugUtils.currentLine=79233046;
 //BA.debugLineNum = 79233046;BA.debugLine="NextSet.Add(it.Panel)";
_nextset._add /*String*/ (null,(Object)(_it.Panel.getObject()));
 }}
;
 }
};
RDebugUtils.currentLine=79233049;
 //BA.debugLineNum = 79233049;BA.debugLine="For Each pnl As B4XView In PrevSet.AsList";
_pnl = new anywheresoftware.b4a.objects.B4XViewWrapper();
{
final anywheresoftware.b4a.BA.IterableList group25 = _prevset._aslist /*anywheresoftware.b4a.objects.collections.List*/ (null);
final int groupLen25 = group25.getSize()
;int index25 = 0;
;
for (; index25 < groupLen25;index25++){
_pnl = (anywheresoftware.b4a.objects.B4XViewWrapper) anywheresoftware.b4a.AbsObjectWrapper.ConvertToWrapper(new anywheresoftware.b4a.objects.B4XViewWrapper(), (java.lang.Object)(group25.Get(index25)));
RDebugUtils.currentLine=79233050;
 //BA.debugLineNum = 79233050;BA.debugLine="If NextSet.Contains(pnl) = False Then";
if (_nextset._contains /*boolean*/ (null,(Object)(_pnl.getObject()))==__c.False) { 
RDebugUtils.currentLine=79233051;
 //BA.debugLineNum = 79233051;BA.debugLine="If pnl.Parent.IsInitialized Then";
if (_pnl.getParent().IsInitialized()) { 
RDebugUtils.currentLine=79233052;
 //BA.debugLineNum = 79233052;BA.debugLine="pnl.RemoveViewFromParent";
_pnl.RemoveViewFromParent();
RDebugUtils.currentLine=79233053;
 //BA.debugLineNum = 79233053;BA.debugLine="pnl.GetView(0).RemoveAllViews";
_pnl.GetView((int) (0)).RemoveAllViews();
RDebugUtils.currentLine=79233054;
 //BA.debugLineNum = 79233054;BA.debugLine="pnl.RemoveAllViews";
_pnl.RemoveAllViews();
RDebugUtils.currentLine=79233055;
 //BA.debugLineNum = 79233055;BA.debugLine="PanelsCache.Add(pnl)";
__ref._panelscache /*anywheresoftware.b4a.objects.collections.List*/ .Add((Object)(_pnl.getObject()));
RDebugUtils.currentLine=79233056;
 //BA.debugLineNum = 79233056;BA.debugLine="Dim it As CLVItem = items.Get(pnl.Tag)";
_it = (b4a.example3.customlistview._clvitem)(__ref._items /*anywheresoftware.b4a.objects.collections.List*/ .Get((int)(BA.ObjectToNumber(_pnl.getTag()))));
RDebugUtils.currentLine=79233057;
 //BA.debugLineNum = 79233057;BA.debugLine="it.Panel = StubPanel";
_it.Panel = __ref._stubpanel /*anywheresoftware.b4a.objects.B4XViewWrapper*/ ;
 };
 };
 }
};
RDebugUtils.currentLine=79233061;
 //BA.debugLineNum = 79233061;BA.debugLine="HandleScrollBar (FirstIndex)";
__ref._handlescrollbar /*String*/ (null,_firstindex);
RDebugUtils.currentLine=79233062;
 //BA.debugLineNum = 79233062;BA.debugLine="Return ListOfItemsThatShouldBeUpdated";
if (true) return __ref._listofitemsthatshouldbeupdated /*anywheresoftware.b4a.objects.collections.List*/ ;
RDebugUtils.currentLine=79233063;
 //BA.debugLineNum = 79233063;BA.debugLine="End Sub";
return null;
}
}