Posts

windows phone 7 - Lazy loading list box, in a panorama page -

i wanted add lazy loading list box(load content when swipe) in panorama page in 1 of windows phone 7 applications. using pivot page. referred this link but not working panorama page. can please me? okay, you're going need 1 of 2 things: use bcl async package (basically adds async tasks , such wp7) or use background worker. highly suggest bcl async package, it's easy on nuget. now, in viewmodel (you using mvvm, yes?) property it's bound to, let's call items should return observablecollection of item type need. now, here's magic happens. in get ter of property, return new collection , use task fill it. this: public observablecollection<object> items { { observablecollection<object> retcollection = new observablecollection<object>(); fillcollection(retcollection); return retcollection; } } public async void fillcollection(observablecollection<object> collectiontofill) { task.factory...

javascript - Jquery find class, value and change background color -

so have code <div class="width100"> <div class="width16 aux"><h1>abc</br>a1</h1><p class="aux-status">50</p></div> <div class="width16 aux"><h1>abc</br>b2</h1><p class="aux-status">24</p></div> <div class="width16 aux"><h1>abc</br>c3</h1><p class="aux-status">24</p></div> <div class="width16 aux"><h1>def</br>1a</h1><p class="aux-status">24</p></div> <div class="width16 aux "><h1>abc</br>d4</h1><p class="aux-status">0</p></div> <div class="width32 aux coomms">have: 12213</div> <div class="width16 aux clear"><h1>abc</br>e5</h1><p class="aux-status">24</p>...

Running JavaScript within a Service in Android -

i have business logic written in javascript, code shared other non-android apps. what best way use functions in piece of javascript within service in android. afaik, there 2 options? v8 built standard webview , superfast, no apk bloat. rhino, tricky going on android? focusing on v8/webview, when attempt access webview, function, get; all webview methods must called on ui thread. future versions of webview may not support use on other threads. the warning being noted, doesn't work now. when set webviewclient up, nothing after loading url. my question in 3 parts; 1) has had success running javascript in webview without ui thread? 2) how results functions inside javascript, webview interface "addjavascriptinterface " support loading parameter , sending java? 3) if either of above impossible.. guess i'll go rhino, tips appreciated, i've seen few blogs complaining of issues regards getting going on android , wondering if there "go to...

android - Generate button states dynamically. -

i have buttons simple png-files. have default normal state. want create pressed state every button dynamically. main aim avoid working png , designer. how can create pressed state using xml or java? if however, looking xml code triggering different imagery based on states, selector placed in res->drawable folder trick. <?xml version="1.0" encoding="utf-8"?> <selector xmlns:android="http://schemas.android.com/apk/res/android" > <item android:state_enabled="false" android:drawable="@drawable/gallerydisabled" /> <item android:state_pressed="true" android:state_enabled="true" android:drawable="@drawable/gallerypressed" /> <item android:state_enabled="true" android:drawable="@drawable/gallerynormal" /> </selector>

.net - Visual Studio 2012 Debugging - Strange scripts (fs.js and l.js) -

Image
i trying debug site on visual studio 2012 and, of sudden, noticed website behaving strangely slower. i checked network tab on browser (ie10) , saw website downloading strange scripts fs.js , l.js. moreover, scripts being downloading repeatedly different urls. see image below: next, went visual studio , saw this: these scripts (that don't recognize, not use or import anywhere) being downloaded infinity, crashing website. any idea can be? seems happen running site on local host.

c++ - Separate STDOUT noise from ncurses -

i trying run ncurses gui application on arm board. running using serial console ttyama0 port. when run ncurses program, other processes running in background print debug messages i.e qdebub, qwarning stdout i.e on gui layout , hence results in noise. think problem because processes using same console device. so there command line or programmatic solution problem not see other process' stdout on ncurses gui ? p.s: have tried gnu screen , gdb solution , work fine. want alternative solution this

java - Stopping the method until another execution finished? -

i have loop adds 50,000 objects arraylist shown below, takes longer time execute. public list<googlefeedentry> getentries(iterator it) { googlefeedutil gfu = new googlefeedutil(host, prefix, domain, servername); list<googlefeedentry> entry = new arraylist<googlefeedentry>(); googlefeedentry gfe; googlefeedentryshipping shipping; while (it.hasnext()) { gfe = new googlefeedentry(); shipping = new googlefeedentryshipping(); productbo product = (productbo) it.next(); entry.add(gfe); } return entry; } after method calling method public void dosomething(){ //some code here } i calling these 2 methods inside method. if put limited number of objects list working out problem. in case of 50,000 objects throwing following exception java.sql.sqlexception: maximum open cursors exceeded ora-01000 i felt nothing oracle(if correct). ofcourse loading objects database. when set break point @ first ...