ဒီတစ္ခုတင္ေပးမွာကေတာ့ MMAS Font Changer ကုိေရးထားတဲ့ Speedy Soft ရဲ႕ APK အထဲက
Coding ေတြကုိ ေဖာ္ျပေပးလုိက္ပါတယ္။
reverse-engineering လုပ္ႏုိင္ဖုိ႕အတြက္ ဒီ Code ေတြကိုေလ့လာႏုိင္ပါတယ္။
Class 7 ခုေရးထားတာေတြ႕ရပါတယ္..
တစ္ခုခ်င္းဆီေရးေပးလုိက္ပါတယ္။
ေဒါင္းခ်င္တဲ့သူေတြလဲဒီမွာေဒါင္းပါ
Download Here
http://www.mediafire.com/?wsfpmi5dd62fkng
R.class
package dev.speedysoft.fontchanger;
public final class R
{
public static final class attr
{
}
public static final class color
{
public static final int Black = 2130968579;
public static final int Gray = 2130968582;
public static final int Red = 2130968577;
public static final int Sky = 2130968580;
public static final int TitleColor = 2130968576;
public static final int White = 2130968578;
public static final int Yellow = 2130968581;
}
public static final class drawable
{
public static final int bg_color = 2130837504;
public static final int icon = 2130837505;
public static final int line = 2130837506;
public static final int line_bg = 2130837507;
public static final int mmas_logo = 2130837508;
public static final int mmaszawgyi = 2130837509;
}
public static final class id
{
public static final int Mails = 2131099672;
public static final int Msg1 = 2131099666;
public static final int Msg2 = 2131099667;
public static final int Msg3 = 2131099668;
public static final int Msg4 = 2131099669;
public static final int Msg5 = 2131099670;
public static final int Msg6 = 2131099671;
public static final int Msg7 = 2131099673;
public static final int btn = 2131099676;
public static final int btnClose = 2131099674;
public static final int btnCredit = 2131099680;
public static final int btnExit = 2131099681;
public static final int btnHelp = 2131099679;
public static final int btnNo = 2131099660;
public static final int btnOK = 2131099661;
public static final int btnSONY = 2131099677;
public static final int btnYes = 2131099659;
public static final int imgLogoView = 2131099649;
public static final int imgView = 2131099675;
public static final int layout1 = 2131099662;
public static final int layout2 = 2131099663;
public static final int layout3 = 2131099664;
public static final int layout4 = 2131099665;
public static final int lblCredit1 = 2131099678;
public static final int lower = 2131099651;
public static final int txtCopyRight = 2131099653;
public static final int txtDescription = 2131099650;
public static final int txtDevBy = 2131099655;
public static final int txtDeveloper = 2131099656;
public static final int txtMessage = 2131099658;
public static final int txtSite = 2131099654;
public static final int txtTitle = 2131099657;
public static final int txtVersion = 2131099652;
public static final int upper = 2131099648;
}
public static final class layout
{
public static final int frm_about = 2130903040;
public static final int frm_confirm_dialog = 2130903041;
public static final int frm_dialog = 2130903042;
public static final int frm_help = 2130903043;
public static final int frm_loading = 2130903044;
public static final int main = 2130903045;
public static final int menu = 2130903046;
}
public static final class string
{
public static final int app_name = 2131034113;
public static final int hello = 2131034112;
}
}
frmHelp.class
package dev.speedysoft.fontchanger;
import android.app.Activity;
import android.graphics.Typeface;
import android.os.Bundle;
import android.view.Display;
import android.view.View;
import android.view.View.OnClickListener;
import android.view.WindowManager;
import android.widget.Button;
import android.widget.TextView;
public class frmHelp extends Activity
{
private Button btnClose;
private Typeface face;
private frmHelp mContext;
private TextView txtMail;
private TextView txtMsg1;
private TextView txtMsg2;
private TextView txtMsg3;
private TextView txtMsg4;
private TextView txtMsg5;
private TextView txtMsg6;
private TextView txtMsg7;
private TextView txtTitle;
public void onCreate(Bundle paramBundle)
{
requestWindowFeature(1);
super.onCreate(paramBundle);
setContentView(2130903043);
this.mContext = this;
this.face = Typeface.createFromAsset(getAssets(), "dsf2.ttf");
this.txtTitle = ((TextView)findViewById(2131099657));
this.txtTitle.setTypeface(this.face);
this.txtMsg1 = ((TextView)findViewById(2131099666));
this.txtMsg1.setTypeface(this.face);
this.txtMsg2 = ((TextView)findViewById(2131099667));
this.txtMsg2.setTypeface(this.face);
this.txtMsg3 = ((TextView)findViewById(2131099668));
this.txtMsg3.setTypeface(this.face);
this.txtMsg4 = ((TextView)findViewById(2131099669));
this.txtMsg4.setTypeface(this.face);
this.txtMsg5 = ((TextView)findViewById(2131099670));
this.txtMsg5.setTypeface(this.face);
this.txtMsg6 = ((TextView)findViewById(2131099671));
this.txtMsg6.setTypeface(this.face);
this.txtMsg7 = ((TextView)findViewById(2131099673));
this.txtMsg7.setTypeface(this.face);
this.txtMail = ((TextView)findViewById(2131099672));
this.txtMail.setTypeface(this.face);
this.btnClose = ((Button)findViewById(2131099674));
this.btnClose.setTypeface(this.face);
if (getWindowManager().getDefaultDisplay().getHeight() > 500)
{
this.txtTitle.setTextSize(20.0F);
this.txtMail.setTextSize(16.0F);
}
this.btnClose.setOnClickListener(new View.OnClickListener()
{
public void onClick(View paramAnonymousView)
{
frmHelp.this.finish();
}
});
}
}
Frmmain.class
package dev.speedysoft.fontchanger;
import android.app.Activity;
import android.content.Intent;
import android.content.res.AssetManager;
import android.graphics.Typeface;
import android.os.Build.VERSION;
import android.os.Bundle;
import android.view.Display;
import android.view.KeyEvent;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.View.OnClickListener;
import android.view.WindowManager;
import android.widget.Button;
import android.widget.TextView;
import android.widget.Toast;
import java.io.DataOutputStream;
import java.io.File;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
public class frmMain extends Activity
{
private int OK_ONLY = 2001;
private int SDK_INT;
private int YESNO = 2002;
private Button btn;
private Button btnSony;
private File fBold;
private File fDSF;
private File fRegular;
private File fRoboBold;
private File fRoboRegular;
private Typeface face;
private frmMain mContext;
private Process p;
private Runtime r;
private TextView txtCredit1;
private TextView txtTitle;
private void copyBold(String paramString)
throws IOException
{
InputStream localInputStream = this.mContext.getAssets().open("bold.ttf");
FileOutputStream localFileOutputStream = new FileOutputStream("/sdcard/data/fonts/bold.ttf");
byte[] arrayOfByte = new byte[1024];
while (true)
{
int i = localInputStream.read(arrayOfByte);
if (i <= 0)
{
localFileOutputStream.flush();
localFileOutputStream.close();
localInputStream.close();
return;
}
localFileOutputStream.write(arrayOfByte, 0, i);
}
}
private void copyRegular(String paramString)
throws IOException
{
InputStream localInputStream = this.mContext.getAssets().open("regular.ttf");
FileOutputStream localFileOutputStream = new FileOutputStream("/sdcard/data/fonts/regular.ttf");
byte[] arrayOfByte = new byte[1024];
while (true)
{
int i = localInputStream.read(arrayOfByte);
if (i <= 0)
{
localFileOutputStream.flush();
localFileOutputStream.close();
localInputStream.close();
return;
}
localFileOutputStream.write(arrayOfByte, 0, i);
}
}
private void copySony(String paramString)
throws IOException
{
InputStream localInputStream = this.mContext.getAssets().open("dsf2.ttf");
FileOutputStream localFileOutputStream = new FileOutputStream("/sdcard/data/fonts/dsf2.ttf");
byte[] arrayOfByte = new byte[1024];
while (true)
{
int i = localInputStream.read(arrayOfByte);
if (i <= 0)
{
localFileOutputStream.flush();
localFileOutputStream.close();
localInputStream.close();
return;
}
localFileOutputStream.write(arrayOfByte, 0, i);
}
}
private void copyThree(String paramString)
throws IOException
{
InputStream localInputStream = this.mContext.getAssets().open("dsf3.ttf");
FileOutputStream localFileOutputStream = new FileOutputStream("/sdcard/data/fonts/dsf3.ttf");
byte[] arrayOfByte = new byte[1024];
while (true)
{
int i = localInputStream.read(arrayOfByte);
if (i <= 0)
{
localFileOutputStream.flush();
localFileOutputStream.close();
localInputStream.close();
return;
}
localFileOutputStream.write(arrayOfByte, 0, i);
}
}
protected void onActivityResult(int paramInt1, int paramInt2, Intent paramIntent)
{
if ((paramInt1 != this.OK_ONLY) && (paramInt1 == this.YESNO) && (paramInt2 == -1))
finish();
}
public void onCreate(Bundle paramBundle)
{
requestWindowFeature(1);
super.onCreate(paramBundle);
setContentView(2130903045);
this.mContext = this;
Toast.makeText(this.mContext, "www.myanmarmobileapp.com", 1).show();
this.face = Typeface.createFromAsset(getAssets(), "dsf2.ttf");
this.txtTitle = ((TextView)findViewById(2131099657));
this.txtTitle.setTypeface(this.face);
this.txtCredit1 = ((TextView)findViewById(2131099678));
this.txtCredit1.setTypeface(this.face);
if (getWindowManager().getDefaultDisplay().getHeight() > 500)
{
this.txtTitle.setTextSize(20.0F);
this.txtCredit1.setTextSize(16.0F);
}
if (!new File("/sdcard/").exists())
{
Intent localIntent = new Intent(this.mContext, frmShowOKDialog.class);
Bundle localBundle = new Bundle();
localBundle.putString("Title", "သတိေပးခ်က္");
localBundle.putString("Message", "SD Card ထည့္ေပးပါ။");
localIntent.putExtras(localBundle);
startActivityForResult(localIntent, this.OK_ONLY);
}
File localFile = new File("/sdcard/data/fonts/");
if (!localFile.exists())
localFile.mkdirs();
try
{
copyBold("");
copyRegular("");
copyThree("");
copySony("");
this.fBold = new File("/system/fonts/DroidSans-Bold.ttf");
this.fRegular = new File("/system/fonts/DroidSans.ttf");
this.fRoboBold = new File("/system/fonts/Roboto-Bold.ttf");
this.fRoboRegular = new File("/system/fonts/Roboto-Regular.ttf");
this.fDSF = new File("/system/fonts/DroidSansFallback.ttf");
}
catch (IOException localIOException1)
{
try
{
this.r = Runtime.getRuntime();
this.p = this.r.exec("su");
this.btn = ((Button)findViewById(2131099676));
this.btn.setTypeface(this.face);
this.btn.setOnClickListener(new View.OnClickListener()
{
public void onClick(View paramAnonymousView)
{
try
{
DataOutputStream localDataOutputStream = new DataOutputStream(frmMain.this.p.getOutputStream());
if (frmMain.this.fDSF.exists())
{
localDataOutputStream.writeBytes("mount -o rw,remount /dev/block/stl9 /system" + "\n");
localDataOutputStream.writeBytes("dd if=/system/fonts/DroidSansFallback.ttf of=/sdcard/data/fonts/DroidSansFallback.ttf" + "\n");
localDataOutputStream.writeBytes("dd if=/sdcard/data/fonts/dsf3.ttf of=/system/fonts/DroidSansFallback.ttf" + "\n");
}
if (frmMain.this.SDK_INT < 11)
{
if (frmMain.this.fBold.exists())
{
localDataOutputStream.writeBytes("mount -o rw,remount /dev/block/stl9 /system" + "\n");
localDataOutputStream.writeBytes("dd if=/system/fonts/DroidSans-Bold.ttf of=/sdcard/data/fonts/DroidSans-Bold.ttf" + "\n");
localDataOutputStream.writeBytes("dd if=/sdcard/data/fonts/bold.ttf of=/system/fonts/DroidSans-Bold.ttf" + "\n");
}
if (frmMain.this.fRegular.exists())
{
localDataOutputStream.writeBytes("mount -o rw,remount /dev/block/stl9 /system" + "\n");
localDataOutputStream.writeBytes("dd if=/system/fonts/DroidSans.ttf of=/sdcard/data/fonts/DroidSans.ttf" + "\n");
localDataOutputStream.writeBytes("dd if=/sdcard/data/fonts/regular.ttf of=/system/fonts/DroidSans.ttf" + "\n");
}
if (frmMain.this.fRoboBold.exists())
{
localDataOutputStream.writeBytes("mount -o rw,remount /dev/block/stl9 /system" + "\n");
localDataOutputStream.writeBytes("dd if=/system/fonts/Roboto-Bold.ttf of=/sdcard/data/fonts/Roboto-Bold.ttf" + "\n");
localDataOutputStream.writeBytes("dd if=/sdcard/data/fonts/bold.ttf of=/system/fonts/Roboto-Bold.ttf" + "\n");
}
if (frmMain.this.fRoboRegular.exists())
{
localDataOutputStream.writeBytes("mount -o rw,remount /dev/block/stl9 /system" + "\n");
localDataOutputStream.writeBytes("dd if=/system/fonts/Roboto-Regular.ttf of=/sdcard/data/fonts/Roboto-Regular.ttf" + "\n");
localDataOutputStream.writeBytes("dd if=/sdcard/data/fonts/regular.ttf of=/system/fonts/Roboto-Regular.ttf" + "\n");
}
}
localDataOutputStream.writeBytes("reboot\n");
Intent localIntent3 = new Intent(frmMain.this.mContext, frmShowLoading.class);
frmMain.this.startActivity(localIntent3);
return;
}
catch (IOException localIOException)
{
Intent localIntent2 = new Intent(frmMain.this.mContext, frmShowOKDialog.class);
Bundle localBundle2 = new Bundle();
localBundle2.putString("Title", "သတိေပးခ်က္");
localBundle2.putString("Message", "ျမန္မာေဖာင့္သြင္းရန္ သင့္ဖုန္းတြင္\n Root Access ရရွိရန္ လိုအပ္သည္။");
localIntent2.putExtras(localBundle2);
frmMain.this.startActivityForResult(localIntent2, frmMain.this.OK_ONLY);
return;
}
catch (Exception localException)
{
Intent localIntent1 = new Intent(frmMain.this.mContext, frmShowOKDialog.class);
Bundle localBundle1 = new Bundle();
localBundle1.putString("Title", "သတိေပးခ်က္");
localBundle1.putString("Message", "ျမန္မာေဖာင့္သြင္းရန္ သင့္ဖုန္းတြင္\n Root Access ရရွိရန္ လိုအပ္သည္။");
localIntent1.putExtras(localBundle1);
frmMain.this.startActivityForResult(localIntent1, frmMain.this.OK_ONLY);
}
}
});
this.btnSony = ((Button)findViewById(2131099677));
this.btnSony.setTypeface(this.face);
this.btnSony.setOnClickListener(new View.OnClickListener()
{
public void onClick(View paramAnonymousView)
{
try
{
DataOutputStream localDataOutputStream = new DataOutputStream(frmMain.this.p.getOutputStream());
if (frmMain.this.fDSF.exists())
{
localDataOutputStream.writeBytes("mount -o rw,remount /dev/block/stl9 /system" + "\n");
localDataOutputStream.writeBytes("dd if=/system/fonts/DroidSansFallback.ttf of=/sdcard/data/fonts/DroidSansFallback.ttf" + "\n");
localDataOutputStream.writeBytes("dd if=/sdcard/data/fonts/dsf2.ttf of=/system/fonts/DroidSansFallback.ttf" + "\n");
}
if (frmMain.this.SDK_INT < 11)
{
if (frmMain.this.fBold.exists())
{
localDataOutputStream.writeBytes("mount -o rw,remount /dev/block/stl9 /system" + "\n");
localDataOutputStream.writeBytes("dd if=/system/fonts/DroidSans-Bold.ttf of=/sdcard/data/fonts/DroidSans-Bold.ttf" + "\n");
localDataOutputStream.writeBytes("dd if=/sdcard/data/fonts/dsf2.ttf of=/system/fonts/DroidSans-Bold.ttf" + "\n");
}
if (frmMain.this.fRegular.exists())
{
localDataOutputStream.writeBytes("mount -o rw,remount /dev/block/stl9 /system" + "\n");
localDataOutputStream.writeBytes("dd if=/system/fonts/DroidSans.ttf of=/sdcard/data/fonts/DroidSans.ttf" + "\n");
localDataOutputStream.writeBytes("dd if=/sdcard/data/fonts/dsf2.ttf of=/system/fonts/DroidSans.ttf" + "\n");
}
if (frmMain.this.fRoboBold.exists())
{
localDataOutputStream.writeBytes("mount -o rw,remount /dev/block/stl9 /system" + "\n");
localDataOutputStream.writeBytes("dd if=/system/fonts/Roboto-Bold.ttf of=/sdcard/data/fonts/Roboto-Bold.ttf" + "\n");
localDataOutputStream.writeBytes("dd if=/sdcard/data/fonts/dsf2.ttf of=/system/fonts/Roboto-Bold.ttf" + "\n");
}
if (frmMain.this.fRoboRegular.exists())
{
localDataOutputStream.writeBytes("mount -o rw,remount /dev/block/stl9 /system" + "\n");
localDataOutputStream.writeBytes("dd if=/system/fonts/Roboto-Regular.ttf of=/sdcard/data/fonts/Roboto-Regular.ttf" + "\n");
localDataOutputStream.writeBytes("dd if=/sdcard/data/fonts/dsf2.ttf of=/system/fonts/Roboto-Regular.ttf" + "\n");
}
}
localDataOutputStream.writeBytes("reboot\n");
Intent localIntent3 = new Intent(frmMain.this.mContext, frmShowLoading.class);
frmMain.this.startActivity(localIntent3);
return;
}
catch (IOException localIOException)
{
Intent localIntent2 = new Intent(frmMain.this.mContext, frmShowOKDialog.class);
Bundle localBundle2 = new Bundle();
localBundle2.putString("Title", "သတိေပးခ်က္");
localBundle2.putString("Message", "ျမန္မာေဖာင့္သြင္းရန္ သင့္ဖုန္းတြင္\n Root Access ရရွိရန္ လိုအပ္သည္။");
localIntent2.putExtras(localBundle2);
frmMain.this.startActivityForResult(localIntent2, frmMain.this.OK_ONLY);
return;
}
catch (Exception localException)
{
Intent localIntent1 = new Intent(frmMain.this.mContext, frmShowOKDialog.class);
Bundle localBundle1 = new Bundle();
localBundle1.putString("Title", "သတိေပးခ်က္");
localBundle1.putString("Message", "ျမန္မာေဖာင့္သြင္းရန္ သင့္ဖုန္းတြင္\n Root Access ရရွိရန္ လိုအပ္သည္။");
localIntent1.putExtras(localBundle1);
frmMain.this.startActivityForResult(localIntent1, frmMain.this.OK_ONLY);
}
}
});
this.SDK_INT = Build.VERSION.SDK_INT;
return;
localIOException1 = localIOException1;
localIOException1.printStackTrace();
}
catch (IOException localIOException2)
{
while (true)
localIOException2.printStackTrace();
}
}
}
public boolean onCreateOptionsMenu(Menu paramMenu)
{
getMenuInflater().inflate(2130903046, paramMenu);
return true;
}
public boolean onKeyDown(int paramInt, KeyEvent paramKeyEvent)
{
if (paramInt == 4)
{
Intent localIntent = new Intent(this.mContext, frmShowConfirmDialog.class);
Bundle localBundle = new Bundle();
localBundle.putString("Title", "ထြက္မည္");
localBundle.putString("Message", "ထြက္မွာေသခ်ာပါသလား?");
localIntent.putExtras(localBundle);
startActivityForResult(localIntent, this.YESNO);
}
return false;
}
public boolean onMenuOpened(int paramInt, Menu paramMenu)
{
return super.onMenuOpened(paramInt, paramMenu);
}
public boolean onOptionsItemSelected(MenuItem paramMenuItem)
{
switch (paramMenuItem.getItemId())
{
default:
case 2131099679:
case 2131099680:
case 2131099681:
}
while (true)
{
return true;
startActivity(new Intent(this.mContext, frmHelp.class));
continue;
startActivity(new Intent(this.mContext, frmShowAboutUs.class));
continue;
Intent localIntent = new Intent(this.mContext, frmShowConfirmDialog.class);
Bundle localBundle = new Bundle();
localBundle.putString("Title", "သတိေပးခ်က္");
localBundle.putString("Message", "ထြက္မွာေသခ်ာပါသလား?");
localIntent.putExtras(localBundle);
startActivityForResult(localIntent, this.YESNO);
}
}
}
frmshowaboutus.class
package dev.speedysoft.fontchanger;
import android.app.Activity;
import android.graphics.Typeface;
import android.os.Bundle;
import android.view.Display;
import android.view.WindowManager;
import android.widget.TextView;
public class frmShowAboutUs extends Activity
{
private Typeface face;
private frmShowAboutUs mContext;
private TextView txtCopyRight;
private TextView txtDescription;
private TextView txtDevBy;
private TextView txtDeveloper;
private TextView txtSite;
private TextView txtVersion;
public void onCreate(Bundle paramBundle)
{
requestWindowFeature(1);
super.onCreate(paramBundle);
setContentView(2130903040);
this.mContext = this;
this.face = Typeface.createFromAsset(getAssets(), "dsf2.ttf");
this.txtDescription = ((TextView)findViewById(2131099650));
this.txtDescription.setTypeface(this.face);
this.txtVersion = ((TextView)findViewById(2131099652));
this.txtVersion.setTypeface(this.face);
this.txtCopyRight = ((TextView)findViewById(2131099653));
this.txtCopyRight.setTypeface(this.face);
this.txtSite = ((TextView)findViewById(2131099654));
this.txtSite.setTypeface(this.face);
this.txtDevBy = ((TextView)findViewById(2131099655));
this.txtDevBy.setTypeface(this.face);
this.txtDeveloper = ((TextView)findViewById(2131099656));
this.txtDeveloper.setTypeface(this.face);
if (getWindowManager().getDefaultDisplay().getHeight() > 500)
{
this.txtDescription.setTextSize(20.0F);
this.txtVersion.setTextSize(20.0F);
this.txtCopyRight.setTextSize(16.0F);
this.txtSite.setTextSize(18.0F);
this.txtDevBy.setTextSize(16.0F);
this.txtDeveloper.setTextSize(20.0F);
}
}
}
frmshowconfirmdialog.class
package dev.speedysoft.fontchanger;
import android.app.Activity;
import android.content.Intent;
import android.graphics.Typeface;
import android.os.Bundle;
import android.view.Display;
import android.view.View;
import android.view.View.OnClickListener;
import android.view.WindowManager;
import android.widget.Button;
import android.widget.TextView;
public class frmShowConfirmDialog extends Activity
{
private Button btnNo;
private Button btnYes;
private Bundle extras;
private Typeface face;
private TextView txtMessage;
private TextView txtTitle;
public void onCreate(Bundle paramBundle)
{
requestWindowFeature(1);
super.onCreate(paramBundle);
setContentView(2130903041);
this.face = Typeface.createFromAsset(getAssets(), "dsf2.ttf");
this.txtTitle = ((TextView)findViewById(2131099657));
this.txtTitle.setTypeface(this.face);
this.txtMessage = ((TextView)findViewById(2131099658));
this.txtMessage.setTypeface(this.face);
this.btnYes = ((Button)findViewById(2131099659));
this.btnYes.setTypeface(this.face);
this.btnNo = ((Button)findViewById(2131099660));
this.btnNo.setTypeface(this.face);
if (getWindowManager().getDefaultDisplay().getHeight() > 500)
this.txtTitle.setTextSize(17.0F);
this.extras = getIntent().getExtras();
if (this.extras != null);
try
{
this.txtTitle.setText(this.extras.getString("Title").toString());
this.txtMessage.setText(this.extras.getString("Message").toString());
label235: this.btnYes.setOnClickListener(new View.OnClickListener()
{
public void onClick(View paramAnonymousView)
{
Intent localIntent = new Intent();
frmShowConfirmDialog.this.setResult(-1, localIntent);
frmShowConfirmDialog.this.finish();
}
});
this.btnNo.setOnClickListener(new View.OnClickListener()
{
public void onClick(View paramAnonymousView)
{
Intent localIntent = new Intent();
frmShowConfirmDialog.this.setResult(0, localIntent);
frmShowConfirmDialog.this.finish();
}
});
return;
}
catch (Exception localException)
{
break label235;
}
}
}
frmshowloading.class
package dev.speedysoft.fontchanger;
import android.app.Activity;
import android.graphics.Typeface;
import android.os.Bundle;
import android.view.Display;
import android.view.KeyEvent;
import android.view.WindowManager;
import android.widget.TextView;
public class frmShowLoading extends Activity
{
private Typeface face;
private TextView txtMessage;
private TextView txtTitle;
protected void onCreate(Bundle paramBundle)
{
requestWindowFeature(1);
super.onCreate(paramBundle);
setContentView(2130903044);
this.face = Typeface.createFromAsset(getAssets(), "dsf2.ttf");
this.txtTitle = ((TextView)findViewById(2131099657));
this.txtTitle.setTypeface(this.face);
this.txtMessage = ((TextView)findViewById(2131099658));
this.txtMessage.setTypeface(this.face);
if (getWindowManager().getDefaultDisplay().getHeight() > 500)
this.txtTitle.setTextSize(17.0F);
}
public boolean onKeyDown(int paramInt, KeyEvent paramKeyEvent)
{
return paramInt == 4;
}
}
frmshowokdialog.class
package dev.speedysoft.fontchanger;
import android.app.Activity;
import android.content.Intent;
import android.graphics.Typeface;
import android.os.Bundle;
import android.view.Display;
import android.view.View;
import android.view.View.OnClickListener;
import android.view.WindowManager;
import android.widget.Button;
import android.widget.TextView;
public class frmShowOKDialog extends Activity
{
private Button btnOK;
private Bundle extras;
private Typeface face;
private TextView txtMessage;
private TextView txtTitle;
public void onCreate(Bundle paramBundle)
{
requestWindowFeature(1);
super.onCreate(paramBundle);
setContentView(2130903042);
this.face = Typeface.createFromAsset(getAssets(), "dsf2.ttf");
this.txtTitle = ((TextView)findViewById(2131099657));
this.txtTitle.setTypeface(this.face);
this.txtMessage = ((TextView)findViewById(2131099658));
this.txtMessage.setTypeface(this.face);
this.btnOK = ((Button)findViewById(2131099661));
this.btnOK.setTypeface(this.face);
if (getWindowManager().getDefaultDisplay().getHeight() > 500)
this.txtTitle.setTextSize(17.0F);
this.extras = getIntent().getExtras();
if (this.extras != null);
try
{
this.txtTitle.setText(this.extras.getString("Title").toString());
this.txtMessage.setText(this.extras.getString("Message").toString());
label211: this.btnOK.setOnClickListener(new View.OnClickListener()
{
public void onClick(View paramAnonymousView)
{
frmShowOKDialog.this.finish();
}
});
return;
}
catch (Exception localException)
{
break label211;
}
}
}
Subscribe to:
Post Comments (Atom)
0 comments:
Post a Comment