[android-developers] [Help] Recognize vertical swiping and vertical scrolling in gridview

2014-04-14 Thread cybersun
Hi all,
I am a junior android dev, I have a question, please help me.

I have a Gridview, include hundred of items (thumbnail images). I set a 
multi-select mode, in this mode, user just need to swipe his finger to 
start selecting multiple items (this case, gridview can not be scrolled). 
And in a normal touch, Gridview still can vertically scroll for user to see 
other thumbnails and continue selecting.

There is an ambiguity between 2 types of vertical action, can you help me?
Many thanks.

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
Android Developers group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-developers+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[android-developers] Create Logcat filtered by Application name

2013-08-16 Thread cybersun
Hi,
I want to print LogCat just for my application when it's running to test.
I can get log message for specified tag (tag was defined in my Activities), 
but I want to print all log messages for my application. If my app was 
crashed, I can find out and fix it.
How can I do that?

I run this to get Log for a specified tag: logcat -v time -d 
AndroidRuntime:E +TAG+:W *:S

Thanks.

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
Android Developers group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-developers+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


[android-developers] Re: Create Logcat filtered by Application name

2013-08-16 Thread cybersun
More, I want to say that I use command in code, not in terminal/command 
line.
From my program, I execute: Runtime.getRuntime().exec(logcat -v time -d 
AndroidRuntime:E +TAG+:W *:S); to get log for a tag.

Thanks.

On Friday, August 16, 2013 2:43:06 PM UTC+7, cybersun wrote:

 Hi,
 I want to print LogCat just for my application when it's running to test.
 I can get log message for specified tag (tag was defined in my 
 Activities), but I want to print all log messages for my application. If my 
 app was crashed, I can find out and fix it.
 How can I do that?

 I run this to get Log for a specified tag: logcat -v time -d 
 AndroidRuntime:E +TAG+:W *:S

 Thanks.


-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
Android Developers group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-developers+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [android-developers] Create Logcat filtered by Application name

2013-08-16 Thread cybersun
Hi TreKing,
after searching hours on google, some experts use logcat with grep 
command, but I can not run it from command line, not like what I expected 
from my testing. So I posted here, hope someone can help.


On Friday, August 16, 2013 3:04:01 PM UTC+7, TreKing wrote:


 On Fri, Aug 16, 2013 at 2:43 AM, cybersun quoc...@gmail.com javascript:
  wrote:

 How can I do that?


 Try the first hit on Google for logcat filter by application


 -
 TreKing http://sites.google.com/site/rezmobileapps/treking - Chicago 
 transit tracking app for Android-powered devices
  

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
Android Developers group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-developers+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


[android-developers] Android webview with multi redirect url

2013-08-14 Thread cybersun
Hi all,
I am creating an app that can edit word documents saved on google drive.
From Android app, my webview will show an document manager page, click on a 
file (an Edit icon on webview), webview will redirect to 
google-drive-document-edit address.

I used a WebViewClient, checked 3 methods: 
onPageStarted, shouldOverrideUrlLoading and onPageFinished, that flow is:

shouldOverrideUrlLoading A, onPageStarted A, onPageFinished A: A is 
document manager page
shouldOverrideUrlLoading B, onPageStarted B: B is my service from own 
server, that get document-google-drive link, then redirect to C.
shouldOverrideUrlLoading C, onPageStarted C: C is 
google-drive-document-edit link
shouldOverrideUrlLoading D, onPageStarted D
shouldOverrideUrlLoading E, onPageStarted E

If my webview just load A, then load direct C, it's no problem. But if load 
A then user click Edit, my webview can not show expected address.
That is problem about redirect page, how can I resolve that?

Here is full LogCat:

--- Already show document manager page, log showed when click Edit icon.
...OVERIDE: 
https://docs.google.com/document/d/1VAqhYXSnua0oQT869u93iF84rB3cRTBFHFeZ1lYgHr8/edit?overridemobile=trueom=truerichtext=false
...STARTED: 
https://docs.google.com/document/d/1VAqhYXSnua0oQT869u93iF84rB3cRTBFHFeZ1lYgHr8/edit?overridemobile=trueom=truerichtext=false

...OVERIDE: 
http://www.google.com/url?sa=pq=https://www.google.com/accounts/ServiceLogin?service%3Dwise%26passive%3Dtrue%26go%3Dtrue%26continue%3Dhttps://docs.google.com/document/d/1VAqhYXSnua0oQT869u93iF84rB3cRTBFHFeZ1lYgHr8/edit?overridemobile%253Dtrue%2526om%253Dtrue%2526richtext%253Dfalse%2526pref%253D2%2526pli%253D1
...STARTED: 
http://www.google.com/url?sa=pq=https://www.google.com/accounts/ServiceLogin?service%3Dwise%26passive%3Dtrue%26go%3Dtrue%26continue%3Dhttps://docs.google.com/document/d/1VAqhYXSnua0oQT869u93iF84rB3cRTBFHFeZ1lYgHr8/edit?overridemobile%253Dtrue%2526om%253Dtrue%2526richtext%253Dfalse%2526pref%253D2%2526pli%253D1

...OVERIDE: 
https://www.google.com/accounts/ServiceLogin?service=wisepassive=truego=truecontinue=https://docs.google.com/document/d/1VAqhYXSnua0oQT869u93iF84rB3cRTBFHFeZ1lYgHr8/edit?overridemobile%3Dtrue%26om%3Dtrue%26richtext%3Dfalse%26pref%3D2%26pli%3D1
...STARTED: 
https://www.google.com/accounts/ServiceLogin?service=wisepassive=truego=truecontinue=https://docs.google.com/document/d/1VAqhYXSnua0oQT869u93iF84rB3cRTBFHFeZ1lYgHr8/edit?overridemobile%3Dtrue%26om%3Dtrue%26richtext%3Dfalse%26pref%3D2%26pli%3D1

...OVERIDE: 
https://accounts.google.com/ServiceLogin?service=wisepassive=truego=truecontinue=https://docs.google.com/document/d/1VAqhYXSnua0oQT869u93iF84rB3cRTBFHFeZ1lYgHr8/edit?overridemobile%3Dtrue%26om%3Dtrue%26richtext%3Dfalse%26pref%3D2%26pli%3D1
...STARTED: 
https://accounts.google.com/ServiceLogin?service=wisepassive=truego=truecontinue=https://docs.google.com/document/d/1VAqhYXSnua0oQT869u93iF84rB3cRTBFHFeZ1lYgHr8/edit?overridemobile%3Dtrue%26om%3Dtrue%26richtext%3Dfalse%26pref%3D2%26pli%3D1

...OVERIDE: 
https://docs.google.com/document/d/1VAqhYXSnua0oQT869u93iF84rB3cRTBFHFeZ1lYgHr8/edit?overridemobile=trueom=truerichtext=falsepref=2pli=1
...STARTED: 
https://docs.google.com/document/d/1VAqhYXSnua0oQT869u93iF84rB3cRTBFHFeZ1lYgHr8/edit?overridemobile=trueom=truerichtext=falsepref=2pli=1

...OVERIDE: 
https://docs.google.com/document/d/1VAqhYXSnua0oQT869u93iF84rB3cRTBFHFeZ1lYgHr8/edit?overridemobile=trueom=truerichtext=falsepli=1
...STARTED: 
https://docs.google.com/document/d/1VAqhYXSnua0oQT869u93iF84rB3cRTBFHFeZ1lYgHr8/edit?overridemobile=trueom=truerichtext=falsepli=1


-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
Android Developers group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-developers+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [android-developers] Best way to save user's avatar

2013-07-23 Thread cybersun
Thank you so much Ryan, I'll dig inside that source, hope that solve my 
problem ;).

On Monday, July 22, 2013 7:56:49 PM UTC+7, Ryan Harter wrote:

 Take a look at that AOSP sources.  You can see that the built in contacts 
 app is saving the photos to the file system.

 On the PhotoStore class in the contacts provider, here is the javadoc 
 comment on the class:


1. /**
2.  * Photo storage system that stores the files directly onto the 
hard disk 
3.  * in the specified directory.
4.  */ 


  
 https://android.googlesource.com/platform/packages/providers/ContactsProvider/+/master/src/com/android/providers/contacts/PhotoStore.java

 I know the subject tends to be a religious war, but I never store binary 
 data in a database unless absolutely necessary.  In this case, use the 
 database to store an id or url of the photo, then have a specified file 
 structure based on that id (could be one large directory with a photo named 
 after each id).

 Remember,  you can also use a content provider to provide access to the 
 file system, so check that out as well.

 Best
 Ryan


 On Sun, Jul 21, 2013 at 11:31 PM, cybersun quoc...@gmail.comjavascript:
  wrote:

 Hi all,
 I am creating an app that user can communication with other friends (IM 
 app, send message, card, ...), so user have provide user's profile like id, 
 name, avatar.
 My question is: what is the best way to save friend's avatar to make 
 local contact list for my app?

 I created a local database for saving contact information, synchronize 
 with a remote database on my server. In my app, can I save avatars into:
 (1) SQLite database?
 (2) SDcard?
 (3) App cache?

 Android Contacts app use Contacts Storage to store contact's avatar, I 
 dont know what implemented inside.

 I saw other apps like Whatsapp,  wechat, line, zalo, ... do not save 
 avatars on SDcard, so where are avatars when contact list has many contacts 
 (100).

 Hope you can help, thanks.

 -- 
 -- 
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to 
 android-d...@googlegroups.comjavascript:
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.com javascript:
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en
 --- 
 You received this message because you are subscribed to the Google Groups 
 Android Developers group.
 To unsubscribe from this group and stop receiving emails from it, send an 
 email to android-developers+unsubscr...@googlegroups.com javascript:.
 For more options, visit https://groups.google.com/groups/opt_out.
  
  




-- 
-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
Android Developers group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-developers+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[android-developers] Best way to save user's avatar

2013-07-21 Thread cybersun
Hi all,
I am creating an app that user can communication with other friends (IM 
app, send message, card, ...), so user have provide user's profile like id, 
name, avatar.
My question is: what is the best way to save friend's avatar to make local 
contact list for my app?

I created a local database for saving contact information, synchronize with 
a remote database on my server. In my app, can I save avatars into:
(1) SQLite database?
(2) SDcard?
(3) App cache?

Android Contacts app use Contacts Storage to store contact's avatar, I dont 
know what implemented inside.

I saw other apps like Whatsapp,  wechat, line, zalo, ... do not save 
avatars on SDcard, so where are avatars when contact list has many contacts 
(100).

Hope you can help, thanks.

-- 
-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
Android Developers group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-developers+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[android-developers] How to insert MS Office word table into Edittext

2012-04-09 Thread cybersun
Hi all,
I want to draw a table contains some texts into my Edittext. I have a
screen to input data at every row, now I need draw that table. Before
inserting table, my Edittext contains some text paragraphs.
Pls give me the answer for this problem.
Thanks.

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: How to insert MS Office word table into Edittext

2012-04-09 Thread cybersun
Thanks,
because I dont know how to insert any View into Edittext. May I custom
that edittext and them draw some vertical, horizontal line to describe
tha table? If yes, how to know the expected location that I want to
draw table?

On 9 Tháng Tư, 16:10, Michael Banzon mich...@banzon.dk wrote:
 That is really not a problem - until now its just a fantastic creative idea.









 On Mon, Apr 9, 2012 at 11:06 AM, cybersun quocnh...@gmail.com wrote:
  Hi all,
  I want to draw atablecontains some texts into myEdittext. I have a
  screen to input data at every row, now I need draw thattable. Before
  insertingtable, myEdittextcontains some text paragraphs.
  Pls give me the answer for this problem.
  Thanks.

  --
  You received this message because you are subscribed to the Google
  Groups Android Developers group.
  To post to this group, send email to android-developers@googlegroups.com
  To unsubscribe from this group, send email to
  android-developers+unsubscr...@googlegroups.com
  For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en

 --
 Michael Banzonhttp://michaelbanzon.com/

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en