Micromax Yureka: Indian Handset with CyanogenMod

Thesoap opera involving Cyanogen Inc., OnePlus, and Micromax is one of the most talked about … more

Chainfire Turns Your Bootanimation into a Logging Center

Having a nice boot animation certainly adds a little bit of aesthetic polish to your … more

Android TV Launcher Pushed to Google Play

Over the past decade, the tech universe has seen two drastic and widely contrasting changes with … more

Cyngn, OnePlus, Micromax – The Legal Battle

Recently, a battle has been waging in India over the rights to distribute the commercial … more

Welcome to XDA

Search to go directly to your device's forum

Register an account

Unlock full posting privileges

Ask a question

No registration required
Post Reply

[How-To] Edit Contacts.apk/Phone.apk for dialer pad ?

OP SmiLeToLife

14th May 2014, 02:27 PM   |  #1  
SmiLeToLife's Avatar
OP Member
Flag Eskişehir
Thanks Meter: 24
 
85 posts
Join Date:Joined: Jul 2012
Donate to Me
More
hi everybody, I need some help with dialer pad.

As you can see at the pic, there is much space at the right. The lowermost buttons are not in proper line. How i can resize them to put them in a proper line? Do I need to edit smali codes / values codes? Thanks in advance

14th May 2014, 02:35 PM   |  #2  
TheArc's Avatar
Recognized Themer
Flag Auckland City
Thanks Meter: 1,862
 
2,393 posts
Join Date:Joined: Jan 2012
Donate to Me
More
The images don't need to be resized.

However you'll have to modify the layout. But this will be a task.
First you'll have to find out which layout it is that contains those three buttons.

The way I narrow my search down is, I go into red/drawable-hdpi/xhdpi/xxhdpi or whatever the resolution is. And look for those icons. Once you find the dialer, phone and contact add icon. Copy the names of these .png's to something then using one of the .png's copy the name and in the layouts folder. Search the images name. This will narrow down the layout.xml's and then from there you can find it. Once you find the layout.
There will be three lines that determine the images, you can fix the layouts by using the following code.

android:layout_gravity="center|center"
android:gravity="center"

Change the first one to where you want to button to be displayed so if its on the right side make it "right|center" or "center|right"

Hopefully I helped.

Sent from my Nexus 5 using Tapatalk
17th May 2014, 04:20 PM   |  #3  
SmiLeToLife's Avatar
OP Member
Flag Eskişehir
Thanks Meter: 24
 
85 posts
Join Date:Joined: Jul 2012
Donate to Me
More
Quote:
Originally Posted by krishneelg3

The images don't need to be resized.

However you'll have to modify the layout. But this will be a task.
First you'll have to find out which layout it is that contains those three buttons.

The way I narrow my search down is, I go into red/drawable-hdpi/xhdpi/xxhdpi or whatever the resolution is. And look for those icons. Once you find the dialer, phone and contact add icon. Copy the names of these .png's to something then using one of the .png's copy the name and in the layouts folder. Search the images name. This will narrow down the layout.xml's and then from there you can find it. Once you find the layout.
There will be three lines that determine the images, you can fix the layouts by using the following code.

android:layout_gravity="center|center"
android:gravity="center"

Change the first one to where you want to button to be displayed so if its on the right side make it "right|center" or "center|right"

Hopefully I helped.

Sent from my Nexus 5 using Tapatalk

thanks for your answer

I tried but doesn't fix it. I found what image it shows at dialer pad. it's '' ic_add_contact_holo_dark '' ( how i found it is? I have change the image with another bigger resolution one. Dialer pad shows it bigger but didnt cover more place ( i have thought that if change the icon wiht bigger one maybe it could cover all transparent space. but it didnt ) so with that way i found which image is that! Then,

I followed ur tellings. '' ic_add_contact_holo_dark '' is in Contacts.apk and the layout xml is '' speed_dial_input_dialog.xml '' . Here is the xml codes :

HTML Code:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout android:orientation="horizontal" android:paddingLeft="15.0dip" android:paddingRight="15.0dip" android:layout_width="fill_parent" android:layout_height="fill_parent"
  xmlns:android="http://schemas.android.com/apk/res/android">
    <EditText android:id="@id/number" android:layout_width="0.0dip" android:layout_height="48.0dip" android:layout_marginTop="16.0dip" android:layout_weight="0.8" android:inputType="phone" />
    <ImageView android:layout_gravity="center_vertical" android:id="@id/contacts" android:layout_width="0.0dip" android:layout_height="48.0dip" android:src="@drawable/ic_add_contact_holo_dark" android:layout_weight="0.2" style="?android:attr/buttonBarButtonStyle" />
</LinearLayout>

I have changed '' android:layout_gravity="center_vertical" '' to android:layout_gravity="center|right"

but doesnt fix it, u have any idea ? really thanks for your help
Last edited by SmiLeToLife; 17th May 2014 at 04:30 PM.
17th May 2014, 04:21 PM   |  #4  
TheArc's Avatar
Recognized Themer
Flag Auckland City
Thanks Meter: 1,862
 
2,393 posts
Join Date:Joined: Jan 2012
Donate to Me
More
Mind pulling the .apk from your device and uploading it? Perhaps I can fix it for you.

Sent from my Nexus 5 using Tapatalk
17th May 2014, 04:28 PM   |  #5  
SmiLeToLife's Avatar
OP Member
Flag Eskişehir
Thanks Meter: 24
 
85 posts
Join Date:Joined: Jul 2012
Donate to Me
More
Quote:
Originally Posted by krishneelg3

Mind pulling the .apk from your device and uploading it? Perhaps I can fix it for you.

Sent from my Nexus 5 using Tapatalk

here is the link: http://yadi.sk/d/ggjXtOnVQVrjt

Contacts.apk , Phone.apk and Framework-res.apk ...

Thanks
18th May 2014, 03:26 AM   |  #6  
TheArc's Avatar
Recognized Themer
Flag Auckland City
Thanks Meter: 1,862
 
2,393 posts
Join Date:Joined: Jan 2012
Donate to Me
More
@SmiLeToLife thanks, I will take a look at it in an hour or so. Just woke up.

I'll let you know if I finish it

EDIT -

Couldn't find the needed layout. Sorry :\
Last edited by TheArc; 20th May 2014 at 06:04 AM.
Post Reply Subscribe to Thread
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes