yashsingh1/xdaforums huggingface dataset:
[Java for Android App Development] nnnn1111:
one question

my problem is , when i run the app, it doesn't show any rows , not even any listview , or string

(just blank white page)

i have two activities

first one is Activity_main.xml in which ive implemented listview

here is it's java file

package com.example.desi;

import android.app.Activity;

import android.content.Intent;

import android.view.View;

import android.widget.AdapterView;

public class MainActivity extends Activity {

String[] items = { "item 1", "item 2", "item 3", "item 4", "item 5" };

public void onItemClick(AdapterView<?> parent, View view,

int position, long id) {

switch( position )

{

case 0: Intent newActivity = new Intent(this, Munda.class);

startActivity(newActivity);

break;

}

}

}

and another activity is Activity_munda.xml

so, i want to run "Activity_munda" through on row click of listview

i also want to have many activities later in my app

my project is error free right now

do you think i have incomplete code?
[Java for Android App Development] vijai2011:
Your code is incomplete. You haven't populated the layout "activity_main.xml" here. and haven't added the list view, So it is indeed correct the app displays a blank page with no errors.
[Java for Android App Development] nikwen:
Right. Read this: http://www.vogella.com/articles/AndroidListView/article.html
[Java for Android App Development] nnnn1111:
i already tried that

but with no luck

its very complicated

can you please give me a simple tutorial ?

please dont refer to any other tutorial as i have already tried all of them,

thanks
[Java for Android App Development] nikwen:
Come on, you haven't tried all of them. Please don't let everyone else do the work for you. And if you can manage to do it yourself, it will be a better learning experience.

I can offer that you try the tutorial I posted and if your code doesn't work, you can post it together with a logcat and we'll check it. ;)
[Java for Android App Development] nnnn1111:
haha i know

but ive been searching for like 15 days about this problem on stack overflow , saw like 30 posts but they arent clear , please do me a favor and

tell me in few steps :p you will also feel good helping me.

and it will be a VERY big favor to me , trust me :D
[Java for Android App Development] nikwen:
Read this about ListActivity. It should answer your questions: http://www.vogella.com/articles/AndroidListView/article.html#listactivity

And I won't post step by step guides on how to implement ListViews. There are many great tutorials out there. I can help you if you have problems/errors with your code, but [MENTION=4311415]vijai2011[/MENTION] has already explained what you need to do.
[Java for Android App Development] vijai2011:
You cannot expect anyone to spoon feed you. We are here to help people who try to do something but run into problems. Not people who doesnt even try to understand what they do. The guides by vogella are very simple and there is no problem with the guide. You cannot simply copy paste the codes from the tutorial and expect it to compile and work.
[Java for Android App Development] nnnn1111:
i didn't find my answer on that website
[Java for Android App Development] vijai2011:
Then it may mean that you dont know what you are searching for! Because the tutorial is all about what you need - ListView!
[Galaxy Y GT-S5360 Android Development] iamareebjamal:
Guide to changing path thickness of Pattern Lockscreen to ICS style​

I wandered places searching this off. I found some traces in direction of my destiny but none of them worked fully correctly

So, as stated, I searched a lot for this mod and came face to face with failures and smali errors. So, I had to figure it out myself some modification to do in it to make it work.

Note: IT is not COMPLETELY my mod but I have done modifications in it to make it work. This is based on a guide for Froyo outside of XDA.

Pre-Requisites:

1. PC with Java JDK or JRE

2. Deodexed ROM

3. 7-Zip

4. classes.dex decompiling tool

5. Notepad++

6. Patience

7. Carefulness for editing smali files

Let's Start

1. First we would have to decompile classes.dex inside framework.jar

For that, you can use my Tool ROM Tool v3

First using 7zip, Right click on your framework.jar and open it as archive and drag and drop classes.dex in input folder of the tool

(Note: If you don't have classes.dex in framework.jar [only META-INF and preloaded-classes.dex], then your framework isn't deodexed)

Now, open Script.bat and choose 1 (Decompile classes.dex)

2. Now, we will make the changes. Go to decompiled folder and go to \classout\com\android\internal\widget and open LockPatternView.smali in Notepad++

Search for mDiameterFactor:F

[Ctrl+F]​

See the code above it.

It should be like this:-

const[COLOR="Red"]/high16[/COLOR] v2, 0x3f00

If it is, then you will have to remove red part /high16

Because it will not allow the change of code we will be doing which will have a different hexadecimal value which will not be supported till this code is in effect

Now, it will look like this:-

const v2, 0x[COLOR="Red"]3f00[/COLOR]

Now, we will change the thickness value 3f00 to 3dcccccd

Final code will look like this

const v2, 0x3dcccccd

Save it

I am attaching final and before smali for comparison below.

View attachment 1936707

(Note: If you don't have /high16, it's good , then just change the value and save)

3. Go to Script.bat again and choose 2 (Recompile classes.dex) and after it's done, you will get classes.dex

Drop it in framework.jar

4. Push framewotk.jar in /system/framework

Eg:

Copy it in platform-tools folder of android SDK and type following with pressing Enter after each command

adb remount
adb push framework.jar /system/framework/
adb shell chmod 644 /system/framework/framework.jar
adb shell killall system_server

Last command will Hot Reboot your phone to apply changes. It is fast and better than rebooting phone.

5. Enjoy

Screenshots

Before

After

Credits​

A member from other forum to answer a question to other member of that forum :p

Google for letting me search somethings

Samsung Galaxy Ace s5830i members for supporting me so much
[Galaxy Y GT-S5360 Android Development] zenxus31:
reserved!!!! :good::good:
[Galaxy Y GT-S5360 Android Development] Bruce Wayne:
For?:eek:

Don't post things like this in guide threads atleast. Reporting:o

A Hero Can Be Anyone.
[Galaxy Y GT-S5360 Android Development] zenxus31:
for question :D:D:D:D
[Galaxy Y GT-S5360 Android Development] Bruce Wayne:
Better go through this post. You need to I say. http://xdaforums.com/showthread.php?p=40990860

A Hero Can Be Anyone.
[Galaxy Y GT-S5360 Android Development] Psykic:
U arE aWeSOME !!

I hav searched so many threads and forums for this ..!!

Thanks man!! :D
[Galaxy Y GT-S5360 Android Development] Droid_beginner_student:
question:

in the shell command,afaik chmod 777 is rw-r--r--

what is 644 stand for?

because adb and shell command new to me (i never use that,and still know little about that),so i want to apply the framework.jar manually via rootex

Sent by a Schoolar Boy ​

Question? Better go to [Help Thread] by Deadly
[Galaxy Y GT-S5360 Android Development] CharsiBabu:
alternate version.

4 - read (r)

2 - write (w)

1 - execute (x)

so 777 implies rwx rwx rwx

and 644 rw r r
[Galaxy Y GT-S5360 Android Development] TechBurner:
Working good!
[Galaxy Y GT-S5360 Android Development] Psykic:
AaaaaaweSoooooomE

View attachment 1937701
[Galaxy Y GT-S5360 Android Development] iamareebjamal:
Thank you all

Looking forward to learn more :)
[Galaxy Y GT-S5360 Android Development] iamareebjamal:
Updated OP with some correction and link to RTv3
[Galaxy Y GT-S5360 Android Development] darkshadow246:
Can you pls make a flashable zip :o

Can't use my PC

Really want this badly

sent from my muffin phone
[Galaxy Y GT-S5360 Android Development] iamareebjamal:
This isn't a universal mod as different ROMs have different framework.jar.

So, it can't be made into Flashable Zip

Sorry :(
[Galaxy Y GT-S5360 Android Development] farizemo:
Violaa..

That was my first modification by my self..!! :) :) :)

Thanks OP :D
[Galaxy Y GT-S5360 Android Development] ProGTXjay:
sir areeb could help me how to add the pattern lock. in op edit only the thickness. my problems is in sgs3 rom dont have this pattern :(
[Galaxy Y GT-S5360 Android Development] iamareebjamal:
It isn't possible(why would someone do that) for a ROM to remove Pattern lock!

It would be there is Settings/Security/Lockscreen
[Galaxy Y GT-S5360 Android Development] parthbhatia98:
Hey I have changed the path thickness...

But how to change the thickness of those dots? Are they pngs or we have to edit some xmls for that too?
[Galaxy Y GT-S5360 Android Development] iamareebjamal:
PNG

But if you edit them heavily and they appear out of place , then xml will come into play
[Galaxy Y GT-S5360 Android Development] parthbhatia98:
Where are those pngs located?? Or which xml to edit?
[AT&T Samsung Galaxy Note II] mrmcpowned:
Ok so I'm getting annoyed with the OTA update messages and useless downloading. From what I've read and confirmed, I need a stock recovery to do this but I'm not sure how to get that back as I'm running TWRP. I've heard of people havinf root survive with this update so I'm pretty confident things won't screw up.
[AT&T Samsung Galaxy Note II] twanskys204:
Flash cf auto root
[AT&T Samsung Galaxy Note II] freakboy13:
Why do you want to do an ota?:confused:

Just disable it and youll be golden.

Have you seen this sticky?

Tons of great info guides roms etc.

http://xdaforums.com/showthread.php?t=1987541

If you really must go back to stock just for that silly ota you can do it via odin or click the link in my signature (web view only sorry ) or look for my guide in q&a.

Both will put you back to a stock recovery my way which is really just instructions for efr, will garauntee you a normal status.

Usually any thing in the ota os already covered by all the great roms we have!

Gl!

:beer:

Edit: to disable ota you need TiBu and just disable or "freeze" everything at&t and the "fw updater". I cant remember specifacaly what they are called because mine our gone thanks to my awesome rom.

Dony delete, freeze only.

Or.... install a nice rom free of bloat ware!
[AT&T Samsung Galaxy Note II] mrmcpowned:
But the thing is I AM ON STOCK, it's just rooted. I want to get back the stock RECOVERY as I have TWRP. Is there really no way to simply do that with a rooted stock firmware and not have to rewrite over everything?
[AT&T Samsung Galaxy Note II] DoctorQMM:
^^^ what twanskys204 recommended in Post#2 ^^^ did you try that? CF Auto-Root will only update the subinary.. install the supersu apk... and flash the stock recovery to the recovery partition.. it will not overwrite your rom (/system or /data partitions) or your modem partition. The only thing is will "rewrite" is the recovery (which you want as it's the stock recovery) and the supersu root. Flashing this will increment the flash counter... but yours is already past "0" since you stated you have TWRP recovery. Besides, you can use TriangeAway app to return flash counter to zero if it's a concern.
[AT&T Samsung Galaxy Note II] mrmcpowned:
Thanks, I needed a bit of an explanation on this. Now to get onward to flashing my recovery :D
[Galaxy Ace S5830 Q&A, Help & Troubleshooting] galaxyace80:
hello

after flashing a few roms, my battery gauge is messed up.

the things i noticed, when my ace turns off deu to low power. the gauge shows 0%.

but when my ace shuts it self down and i plug in the wall charger. the battery gauge shows me a percentage around 75%.

the things i have done to solve this problem is deleting battery stats by cwm and a calibration app nothing did solve the problem.

also i have let the battery drain to zero and then charge it up to 100 and let it drain to zero again. also that didnt solve my problem.

so i flashed back the stock rom by odin. also not solving the problem.

is ther another way to solve the problem
[Galaxy Ace S5830 Q&A, Help & Troubleshooting] Galaxy_Rohit:
Get a new battery.:thumbup::)

Sent Via XDA™ Premium
[Galaxy Ace S5830 Q&A, Help & Troubleshooting] Venomous Viper 119:
The problem is not with your battery. It's with the battery notifier in the ace. It works well for a time and then goes absolutely crazy. Whenever your battery gets low, about 10% for example, connect the charger and charge blindly for 3 hours. Don't worry about the 100% notification. Try your battery now. It should be fine now. But if you're using battery extender kernel, there's a bug in it that brings down the battery for 50% in a short time after using.
[Galaxy Ace S5830 Q&A, Help & Troubleshooting] galaxyace80:
i`am on stock gingerbread, the phone is about two years old. i also noticed that when i turn of my phone and pull the battery out for about three minutes en then put it back in the percentage is higher. so i do think that the battery gauge is messed p but when i use a calibration app to solve it, it gets worse or doesnt change. when i use code *#*#4636#*#* the status of my battery is good. im thinking to buy a new battery but i doubt that it would solve my problem.
[Galaxy Ace S5830 Q&A, Help & Troubleshooting] Venomous Viper 119:
Calibration is all fake. Do as I said and you'll definitely witness the results. ;)
[Galaxy Ace S5830 Q&A, Help & Troubleshooting] Liell:
Hi, I have the same problem with the ace of my wife. When I charge it, it says 100% after 10 min charging !

And when I use it not charging, it drops down ...

I try to let it charge longer, but is that sure that the battery continue charging even if the notifier indicates 100% ?

I'm on [ROM] CM7.2-DEMOCRACY FINAL EDITION .. is there also a kernel to change to help ?

Thanks for your answers, by default I will let it charge for 3h.

PS : is there an app to check the battery life ?
[Galaxy Ace S5830 Q&A, Help & Troubleshooting] galaxyace80:
i did what you said and it seems to solve the problem step by step
[Galaxy Ace S5830 Q&A, Help & Troubleshooting] galaxyace80:
in dialer u must enter the code *#*#4636#*#* there will appear 4 tabs there is one for battery tap it and you wil see the health of youre battery.
[Galaxy Ace S5830 Q&A, Help & Troubleshooting] Venomous Viper 119:
Guys, forget about battery level notification, etc. Any app doing so would collect the info from the android itself. Just do as I said. Everything will be fine.
[Galaxy Ace S5830 Q&A, Help & Troubleshooting] Haer:
I've the same issue. I charged it for 3 hours, it's not fine, it goes to 50% in about 15 minutes, and when I reboot my Ace, it drop to 15% !

I noticed that when I turn it off and charge it, the green battery indicator is at 80%...

Any idea ?

I tried differents ROM such as CM10.1 CM10 CM9,PAC, same issue.
[Galaxy Ace S5830 Q&A, Help & Troubleshooting] Liell:
I bought my wife a new battery [MENTION=252019]2000[/MENTION]mA and she lasts 2 days now, so the answer seems to be the battery-life ...
[Galaxy Ace S5830 Q&A, Help & Troubleshooting] Mandark52:
its a bit risky! u r using 2000mA for 1350mA phone.
[Galaxy Ace S5830 Q&A, Help & Troubleshooting] omega_warrior:
CM 9, 10.1,PAC consume battery like hell, but not that much also.

If there r such huge drops that too after charging the fone for 3 hrs then i guess there is a problem with the battery.

---------- Post added at 04:36 AM ---------- Previous post was at 04:35 AM ----------

Yup u can use without any problem untill voltage n other parameters are as per requirements...
[Galaxy Ace S5830 Q&A, Help & Troubleshooting] Haer:
Yes I thing the battery is dead, it's slightly inflated...
[Galaxy Ace S5830 Q&A, Help & Troubleshooting] jeromejeremytay:
I too have the crazy battery problem, but funny thing is if i were to ignore the indicator and just use it from a 3hr-full charge till it dies off, i could achieve 2.5hours of internet surfing (wifi not 3g). To me this is good enough, all calibration fixes do not work for me. Any suggestions?

PS: I have the system time problem too with S'perience Rom, Eg. when i shut down the phone at 1pm to remove the simcard, after booting up the phone the time shows 11am. This happened to me more than 5 times this week. I dono if it's the rom or the battery that gives this problem. I dono about how it was when running stock rom because this phone does not belong to me. Any help is much appreciated.
[Galaxy Ace S5830 Q&A, Help & Troubleshooting] Viper The Ripper:
Try a full discharge and then plug your phone until it is fully charged, finally without unplug it boot into CWM and wipe battery stats, finally reboot and charge it until 100%
[General Questions and Answers] delickate:
Hi,

I am trying to load google map v1 on android application but only able to see grid. no map. Guide please what thing i am missing?

My main activity file is:

**************************************************************************

package com.example.mymapactivity;

import android.annotation.SuppressLint;

import android.app.Activity;

import android.os.Bundle;

import android.view.Menu;

import com.google.android.gms.maps.CameraUpdateFactory;

import com.google.android.gms.maps.GoogleMap;

import com.google.android.gms.maps.MapFragment;

import com.google.android.gms.maps.model.BitmapDescriptorFactory;

import com.google.android.gms.maps.model.LatLng;

import com.google.android.gms.maps.model.Marker;

import com.google.android.gms.maps.model.MarkerOptions;

public class MyMapActivity extends Activity {

static final LatLng HAMBURG = new LatLng(53.558, 9.927);

static final LatLng KIEL = new LatLng(53.551, 9.993);

private GoogleMap map;

[MENTION=1299008]supp[/MENTION]ressLint("NewApi")

[MENTION=439709]override[/MENTION]

protected void onCreate(Bundle savedInstanceState) {

super.onCreate(savedInstanceState);

setContentView(R.layout.activity_my_map);

map = ((MapFragment) getFragmentManager().findFragmentById(R.id.map))

.getMap();

Marker hamburg = map.addMarker(new MarkerOptions().position(HAMBURG)

.title("Hamburg"));

Marker kiel = map.addMarker(new MarkerOptions()

.position(KIEL)

.title("Kiel")

.snippet("Kiel is cool")

.icon(BitmapDescriptorFactory

.fromResource(R.drawable.ic_launcher)));

// Move the camera instantly to hamburg with a zoom of 15.

map.moveCamera(CameraUpdateFactory.newLatLngZoom(HAMBURG, 15));

// Zoom in, animating the camera.

map.animateCamera(CameraUpdateFactory.zoomTo(10), 2000, null);

}

[MENTION=439709]override[/MENTION]

public boolean onCreateOptionsMenu(Menu menu) {

// Inflate the menu; this adds items to the action bar if it is present.

getMenuInflater().inflate(R.menu.my_map, menu);

return true;

}

}

Please guide

Thanks
[Sony Xperia P, U, Sola, Go] doctor_droid:
op modified

new commands added
[Sony Xperia P, U, Sola, Go] doctor_droid:
Reserved just in case ;)
[Sony Xperia P, U, Sola, Go] Anthrax:
Nice tut doctor g...
[Sony Xperia P, U, Sola, Go] darQ96:
thanx a lot for this, keep it up&going !
[Sony Xperia P, U, Sola, Go] percy_g2:
For windows fan qtadb is much better I prefer Linux but used qtadb :beer:
[Sony Xperia P, U, Sola, Go] WiMARSHANA:
Thanks mate
[Sony Xperia P, U, Sola, Go] cranknet:
Thanks Bro, Great Tuto !!!:victory:
[Sony Xperia P, U, Sola, Go] Guich:
There are a lot of command :)

However, nothing ;)
[Sony Xperia P, U, Sola, Go] Penacal:
Interesting;)
[Sony Xperia P, U, Sola, Go] DaRk-L0rD:
Just what i was looking for! Thank you mate, great work!
[Sony Xperia P, U, Sola, Go] gagounette:
Great tuto, well explained ;)
[Sony Xperia P, U, Sola, Go] Pandemic:
Nice done, good explained :)

..::[ Pandemic ]...:: Face The Insanity With My Xperia P

.....:::: Jelly Bean Moonbreakers Member 4 Ever ::::....
[Sony Xperia P, U, Sola, Go] hiratafabio:
Good and simple tutorial, thanks!

I have a question, though. Today I pushed a file from my PC to my device and it went OK, but when I tried to push another, all I got was the adb command list, as if I typed 'adb help'. I killed adb server, restarted it, no luck. Restarted the phone, no luck either. Tried 'adb device' to see if listed the device and it did, do it was connected.

What can it be?
[Sony Xperia P, U, Sola, Go] doctor_droid:
Try

Adb start-server

Adb remount
[Sony Xperia P, U, Sola, Go] hiratafabio:
Will try, thanks!

Edit: No luck, when giving 'adb remount', system says 'Operation not permitted'
[Sony Xperia P, U, Sola, Go] doctor_droid:
Okay when u open cmd

Make sure u run it as administrator

Secondly

Try adb root

Which rom are u using???

Edit _ just saw ur signature :D
[Sony Xperia P, U, Sola, Go] hiratafabio:
My user has administrator rights, so I guess it's OK, right?

Funny thing is that works for only one push, if I try another, it doesn't work.

adb root gives 'adbd cannot run in production builds' error.

I guess I figured it out: filenames can't have spaces, is this correct? I tried pushing files that have spaces and it didn't work. When I renamed them, it worked like a charm. First I thought the problem was the path, that adb couldn't push files that were two or more levels inside folders, but some I was able to push, others I wasn't, but I also figured out that the path can't have spaces on it.

So that's it, no spaces in both path and filenames do the trick. I think it's a good tip to have in the OP, so people get aware of it if they face a problem just like I did.

Thanks again!
[Sony Xperia P, U, Sola, Go] doctor_droid:
Lol buddy yes files names cant have spaces and also u need to take care of upper n lower case ;)

Edit _ I will add this to op [MENTION=4487307]hiratafabio[/MENTION].. Thanks :)
[Sony Xperia P, U, Sola, Go] Penacal:
Awaiting part 2:)

Free to choose....
[Sony Xperia P, U, Sola, Go] RoBo73:
Nice guide. Thanks.
[Sony Xperia P, U, Sola, Go] mohammadagha:
perfect tutorial but very short, please develope it.
[Sony Xperia P, U, Sola, Go] Anthrax:
That's why it's mentioned in OP part 1.... :p:p:p:p
[Sony Xperia P, U, Sola, Go] PrakashGD:
Interesting these I now already. I want to know to mount any system folder
[Sony Xperia P, U, Sola, Go] aa212121:
Thanks for tut!

Can someone point me to making this work on Linux? I'm trying to switch to Linux and only kept PC on dual boot cuz I'm not sure of Android on Linux.
[Sony Xperia P, U, Sola, Go] simiyet:
Thanks alot. Keep it up!
[AT&T, Rogers HTC One X, Telstra One XL] tmf123:
Hello everyone!

I have a problem:

I wanted to flash a custom rom ("aokp_evita_jb-mr1_milestone-1.zip" (That's Android 4.2.2)). It has looked like it was succesfull, the phone booted normally. At the lockscreen, the touchscreen didn't respond, so I couldn't unlock the screen, but the volume and the power buttons have worked! :confused:

I've done these steps:

- NANDroid Backup

- booted to bootloader

- fastboot flash boot boot.img (extracted from AOKP.zip)

- booted to recovery

- factory reset

- install AOKP.zip

- install gapps-jb-20130301-signed.zip

- reboot system

Here is some information from the bootloader which can be helpful:

*** TAMPERED ***

*** UNLOCKED ***

EVITA PVT SHIP S-ON RL

HBOOT-2.14.0000

RADIO-0.23a.32.09.29

OpenDSP-v31.1.0.45.0815

eMMC-boot

Nov 26 2012, 18:37:14:-1

Do you have an idea how to fix this problem?

Thank you very much!
[AT&T, Rogers HTC One X, Telstra One XL] jerrycoffman45:
you need to downgrade your touchscreen firmware

http://xdaforums.com/showthread.php?t=2159863
[AT&T, Rogers HTC One X, Telstra One XL] tmf123:
Thank you very much!

Thank you very much!

It works now! :D:D:D:D:D
[Android Q&A, Help & Troubleshooting] xkons:
Hey xda community :D

I want to get an upgrade from my galaxy S i9000.

So I'm thinking of buying a Newman N2 China Phone.

I've found a bunch of really good custom Roms for that phone.

But the only problem is, they require CWM to be flashed.

I can't find a Newman N2 specific CWM package.

So can i flash just any of them?

Please help :D
[Android Q&A, Help & Troubleshooting] Shantou88:
So do you know if it's phone model specific? I want to root my G7106 but can find only info related to G7102