This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static void uploadAvatar(InputStream avatarStream, String fileName, AsyncHttpResponseHandler responseHandler) { | |
RequestParams params = new RequestParams(); | |
params.put("avatar", avatarStream, fileName, "image/jpeg"); | |
asyncRequest(null, AVATAR_PATH, params, responseHandler, Method.POST,null); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
g cursorAdapter? | |
<kevin_schultz> xviv, cursoradapter is not deprecated | |
* xviv has quit (Read error: Connection reset by peer) | |
<kevin_schultz> http://developer.android.com/reference/android/widget/CursorAdapter.html | |
<kevin_schultz> one constructor is | |
* xviv (~revanthem@subs11-223-255-227-11.three.co.id) has joined #android-dev | |
* brian_de has quit (Ping timeout: 256 seconds) | |
<kevin_schultz> i generally use CursorAdapter(context, cursor, CursorAdapter.FLAG_REGISTER_CONTENT_OBSERVER) | |
<kevin_schultz> but they definitely are not deprecating cursoradapter | |
<xviv> wait, can you repeat your answer please? because my bad internet connection :| |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static boolean hasInternetConnection(Context context) { | |
ConnectivityManager connMgr = (ConnectivityManager) context.getSystemService(Context.CONNECTIVITY_SERVICE); | |
NetworkInfo wifiNetworkInfo = connMgr.getNetworkInfo(ConnectivityManager.TYPE_WIFI); | |
boolean isWifiConn = false; | |
if(wifiNetworkInfo != null) { | |
isWifiConn = wifiNetworkInfo.isConnected(); | |
} | |
NetworkInfo mobileNetworkInfo = connMgr.getNetworkInfo(ConnectivityManager.TYPE_MOBILE); | |
boolean isMobileConn = false; | |
if(mobileNetworkInfo != null) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static boolean hasInternetConnection(Context context) { | |
ConnectivityManager connMgr = (ConnectivityManager) context.getSystemService(Context.CONNECTIVITY_SERVICE); | |
NetworkInfo[] allNetworkInfo = connMgr.getAllNetworkInfo(); | |
boolean isConnected = false; | |
for(NetworkInfo ni : allNetworkInfo) { | |
if(ni.isConnected()) { | |
isConnected = true; | |
break; | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if(selection.contains(LuaApi.ARG_PAGE)) { | |
long projectId = Long.parseLong(selectionArgs[0]); | |
int page = Integer.parseInt(selectionArgs[selectionArgs.length-1]); | |
pageLessSelection = selection.replace(LuaApi.ARG_PAGE, ""); | |
pageLessselectionArgs = new String[selectionArgs.length - 1]; | |
for(int i = 0; i < selectionArgs.length - 1; i++) { | |
pageLessselectionArgs[i] = selectionArgs[i]; | |
} | |
LuaApi.getInstance().getProjectUploads(projectId, page, updateAllUploadsHandler.get()); | |
} else if (selection.contains(FilesDB.Upload.COLUMN_NAME_ID)) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
WARNING: Untrapped Error in Servlet | |
javax.servlet.ServletException: org.apache.commons.jelly.JellyTagException: jar:file:/var/cache/jenkins/war/WEB-INF/lib/instance-identity-1.3.jar!/org/jenkinsci/main/modules/instance_identity/PageDecoratorImpl/httpHeaders.jelly:2:74: <st:header> finished | |
at org.kohsuke.stapler.jelly.JellyFacet$1.dispatch(JellyFacet.java:103) | |
at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:685) | |
at org.kohsuke.stapler.Stapler.invoke(Stapler.java:799) | |
at org.kohsuke.stapler.Stapler.invoke(Stapler.java:587) | |
at hudson.init.impl.InstallUncaughtExceptionHandler$1.reportException(InstallUncaughtExceptionHandler.java:25) | |
at org.kohsuke.stapler.compression.CompressionFilter.reportException(CompressionFilter.java:63) | |
at org.kohsuke.stapler.compression.CompressionFilter.doFilter(CompressionFilter.java:49) | |
at winstone.FilterConfiguration.execute(FilterConfiguration.java:194) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Copyright (C) 2007 The Android Open Source Project | |
* | |
* Licensed under the Apache License, Version 2.0 (the "License"); | |
* you may not use this file except in compliance with the License. | |
* You may obtain a copy of the License at | |
* | |
* http://www.apache.org/licenses/LICENSE-2.0 | |
* | |
* Unless required by applicable law or agreed to in writing, software |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ViewTag | |
------- | |
Summary: Finds potential leaks when using View.setTag | |
Priority: 6 / 10 | |
Severity: Warning | |
Category: Performance | |
Prior to Android 4.0, the implementation of View.setTag(int, Object) would | |
store the objects in a static map, where the values were strongly referenced. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
LANGUAGE=en_US:en | |
LANG=en_US.UTF-8 | |
ANDROID_HOME DEFAULT=${HOME}/dev/android-sdk | |
PATH DEFAULT=${PATH}:${ANDROID_HOME}/tools:${ANDROID_HOME}/platform-tools:${ANDROID_HOME}:${ANDROID_HOME}/build-tools/18.0.1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FATAL EXCEPTION: AsyncTask #4 | |
java.lang.RuntimeException: An error occured while executing doInBackground() | |
at android.os.AsyncTask$3.done(AsyncTask.java:299) | |
at java.util.concurrent.FutureTask.finishCompletion(FutureTask.java:352) | |
at java.util.concurrent.FutureTask.setException(FutureTask.java:219) | |
at java.util.concurrent.FutureTask.run(FutureTask.java:239) | |
at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:230) | |
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1080) | |
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573) | |
at java.lang.Thread.run(Thread.java:856) |
OlderNewer