titanium-mobile

libpng warning: iCCP: Not recognizing known sRGB profile that has been edited

对着背影说爱祢 提交于 2019-11-29 09:26:54
I am trying to change the color of the cursor in TextField in Titanium android app. For that I created platform/android/res/values/ folder. I placed the following code in tiapp.xml : <android xmlns:android="http://schemas.android.com/apk/res/android"> <manifest> <application android:theme="@style/Theme.Titanium"> </application> <uses-sdk android:minSdkVersion="22" android:targetSdkVersion="22"/> </manifest> </android> When I am trying to run the app, getting the following error. I am working on 3.4.1. API Level is 22 only. [ERROR] : Failed to package application: [ERROR] : [ERROR] : /var

How to check if array element exists or not in javascript?

瘦欲@ 提交于 2019-11-28 15:29:17
I am working with Titanium, my code looks like this: var currentData = new Array(); if(currentData[index]!==""||currentData[index]!==null||currentData[index]!=='null') { Ti.API.info("is exists " + currentData[index]); return true; } else { return false; } I am passing an index to the array currentData . I am still not able to detect a non-existing element using above code. Use typeof arrayName[index] === 'undefined' i.e. if(typeof arrayName[index] === 'undefined') { // does not exist } else { // does exist } yeswanth var myArray = ["Banana", "Orange", "Apple", "Mango"]; if (myArray.indexOf

Titanium Mobile: cant navigate between pages

雨燕双飞 提交于 2019-11-28 14:39:19
i am new to Titanium and i am have 2 seemingly simple problems while trying to use it for the Android. 1) i am trying to navigate to the next page on click of a button. but instead it is showing me a blank black screen. i know my second page CreateNewMeetup.js is correct because i tried displaying it as the landing page of my app and it works. my codes are as follows:- ApplicationWindow.js ... var button = Ti.UI.createButton({ height:44, width:'auto', title:'Create New Meetup', top:20 }); self.add(button); button.addEventListener('click', function() { var newWindow = Ti.UI.createWindow({ url :

What is the correct way to chain async calls in javascript?

北战南征 提交于 2019-11-28 05:59:27
I'm trying to find the best way to create async calls when each call depends on the prior call to have completed. At the moment I'm chaining the methods by recursively calling a defined process function as illustrated below. This is what I'm currently doing. var syncProduct = (function() { var done, log; var IN_CAT = 1, IN_TITLES = 2, IN_BINS = 3; var state = IN_CAT; var processNext = function(data) { switch(state) { case IN_CAT: SVC.sendJsonRequest(url("/api/lineplan/categories"), processNext); state = IN_TITLES; break; case IN_TITLES: log((data ? data.length : "No") + " categories retrieved!

libpng warning: iCCP: Not recognizing known sRGB profile that has been edited

倖福魔咒の 提交于 2019-11-28 02:51:50
问题 I am trying to change the color of the cursor in TextField in Titanium android app. For that I created platform/android/res/values/ folder. I placed the following code in tiapp.xml : <android xmlns:android="http://schemas.android.com/apk/res/android"> <manifest> <application android:theme="@style/Theme.Titanium"> </application> <uses-sdk android:minSdkVersion="22" android:targetSdkVersion="22"/> </manifest> </android> When I am trying to run the app, getting the following error. I am working

What is the correct way to chain async calls in javascript?

风格不统一 提交于 2019-11-27 01:13:32
问题 I'm trying to find the best way to create async calls when each call depends on the prior call to have completed. At the moment I'm chaining the methods by recursively calling a defined process function as illustrated below. This is what I'm currently doing. var syncProduct = (function() { var done, log; var IN_CAT = 1, IN_TITLES = 2, IN_BINS = 3; var state = IN_CAT; var processNext = function(data) { switch(state) { case IN_CAT: SVC.sendJsonRequest(url("/api/lineplan/categories"),