ChildOfCode


Code, Maker, Robotic, Open Source. Knowledge Bases


  1. IOS Get the Apps data Files from Devices

    IOS Get the Apps data Files from Devices 1)Open the Xcode Go to Windows > Devices > Choose the Target Device > click the gear icon and select Download Container. 2)Drop and Drag the xcappdata file in to the SublimeText IDE 3)Open the Side Bar for Explore the Files Root…

    on IOS, Apps Data Files, SublimeText, JSON, MacOS, Xcode

  2. Memory Leaks In Titanium apps

    Solution 1.Remove all the remove all not necessary event listener. 2.Remove all the SetInterval Function. Method for using Geolocation location Event Listener function LocationClass(parent) { this.Parent = parent; var thisClass = this; //Geolocation Setup Ti.Geolocation.accuracy = Ti.Geolocation.ACCURACY_HIGH; Ti.Geolocation.distanceFilter = 10; Ti.Geolocation.preferredProvider = Ti.…

    on Titanium, Memory Leaks, EventListener, Geolocation, removeEventListener

  3. JQuery addClass render

    A solution for the Jquery add class can't render issue. CSS /* Render at First */ #targetDiv { padding: 0px 25px 0px 5px; margin: 0px; position: absolute; right: 0; top: 43px; } /* Rerender the Div */ .TargetDiv_addClass { top: 0px !important; } JavaScript TargetDiv.addClass("TargetDiv_addClass"); The !important exception When an !important rule is used…

    on CSS, !important, JQuery, addClass, render

  4. JavaScript CallBack

    ComponentOne.js function ComponentOneClass(parent) { this.Parent = parent; var thisClass = this; //Properties this.responseCallback = null; }; ComponentOneClass.prototype.ProcessAction = function(theValue) { if(theValue){ this.responseCallback("Callback return"); }else{ Ti.API.log("Get Error"); }; }; ComponentOneClass.prototype.CallOtherMethod = function(theValue,theCallback) { this.responseCallback = theCallback; theProcess = this.ProcessAction(theValue); }; //finally, export the module module.…

    on mobile, JavaScript, Titanium, CallBack

  5. Checking whether a value is an integer in JavaScript

    working on the Titanium Android Nativr Module. In titnaium JavaScript we need to check if the return result is an integer from Java to Javascript. Sometimes the return is a number but the output type is in String Type. if(checkInput % 1 === 0){ //do what you want . }; Refer: http://www.…

    on JavaScript, Check Integer