Skip to content

Commit

Permalink
About US - Full Screen Mode - Arabic Sura Names
Browse files Browse the repository at this point in the history
  • Loading branch information
Hussein Maher committed Aug 10, 2010
1 parent 180946c commit 7bea783
Show file tree
Hide file tree
Showing 17 changed files with 409 additions and 73 deletions.
38 changes: 19 additions & 19 deletions AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,27 +1,27 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.quran.labs.androidquran"
android:versionCode="1"
android:versionName="1.0">
<application android:icon="@drawable/icon" android:label="@string/app_name"
android:debuggable="true">
<activity android:name=".QuranActivity"
android:label="@string/app_name"
android:configChanges="keyboardHidden|orientation">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
package="com.quran.labs.androidquran" android:versionCode="1"
android:versionName="1.0">
<application android:icon="@drawable/icon" android:label="@string/app_name"
android:debuggable="true">
<activity android:name=".QuranActivity" android:label="@string/app_name"
android:configChanges="keyboardHidden|orientation">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>

<activity android:name=".QuranDataActivity"></activity>
<activity android:name=".QuranViewActivity"></activity>
<service android:enabled="true" android:name=".service.QuranDataService" />
</application>
<uses-sdk android:minSdkVersion="3" android:targetSdkVersion="7" />
<activity android:name=".AboutUsActivity"></activity>
<activity android:name=".QuranViewActivity"></activity>
<service android:enabled="true" android:name=".service.QuranDataService" />
<activity android:name=".SettingsActivity"></activity>
</application>
<uses-sdk android:minSdkVersion="3" android:targetSdkVersion="7" />

<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />


</manifest>
71 changes: 50 additions & 21 deletions gen/com/quran/labs/androidquran/R.java
Original file line number Diff line number Diff line change
Expand Up @@ -11,43 +11,72 @@ public final class R {
public static final class attr {
}
public static final class drawable {
public static final int icon=0x7f020000;
public static final int list=0x7f020001;
public static final int splash=0x7f020002;
public static final int about=0x7f020000;
public static final int icon=0x7f020001;
public static final int jump=0x7f020002;
public static final int list=0x7f020003;
public static final int settings=0x7f020004;
public static final int splash=0x7f020005;
}
public static final class id {
public static final int bgPageview=0x7f050004;
public static final int cancelButton=0x7f050001;
public static final int jumpButton=0x7f050002;
public static final int pageScrollView=0x7f050006;
public static final int page_field=0x7f050000;
public static final int pageview=0x7f050005;
public static final int splashview=0x7f050007;
public static final int surarow=0x7f050003;
public static final int bgPageview=0x7f06000b;
public static final int btnAboutBack=0x7f060005;
public static final int btnEmailUs=0x7f060006;
public static final int cancelButton=0x7f060008;
public static final int chkArbaicNames=0x7f06000e;
public static final int chkHideTitle=0x7f06000f;
public static final int jumpButton=0x7f060009;
public static final int linear=0x7f060000;
public static final int menu_item_about_us=0x7f060012;
public static final int menu_item_jump=0x7f060011;
public static final int menu_item_settings=0x7f060013;
public static final int pageScrollView=0x7f06000d;
public static final int page_field=0x7f060007;
public static final int pageview=0x7f06000c;
public static final int splashview=0x7f060010;
public static final int surarow=0x7f06000a;
public static final int txtAbout=0x7f060001;
public static final int txtCopyRights=0x7f060004;
public static final int txtDevelopedBy=0x7f060003;
public static final int txtSupport=0x7f060002;
}
public static final class layout {
public static final int jump_to=0x7f030000;
public static final int quran_error=0x7f030001;
public static final int quran_list=0x7f030002;
public static final int quran_row=0x7f030003;
public static final int quran_view=0x7f030004;
public static final int splash_screen=0x7f030005;
public static final int about_us=0x7f030000;
public static final int jump_to=0x7f030001;
public static final int quran_error=0x7f030002;
public static final int quran_list=0x7f030003;
public static final int quran_row=0x7f030004;
public static final int quran_view=0x7f030005;
public static final int settings=0x7f030006;
public static final int splash_screen=0x7f030007;
}
public static final class menu {
public static final int option_menu=0x7f050000;
}
public static final class string {
public static final int aboutUs=0x7f040015;
public static final int app_name=0x7f040001;
public static final int cancel=0x7f04000e;
public static final int cancel=0x7f040010;
public static final int copyRights=0x7f040012;
public static final int developedBy=0x7f040011;
public static final int downloadPrompt=0x7f040003;
public static final int downloadPrompt_no=0x7f040005;
public static final int downloadPrompt_ok=0x7f040004;
public static final int downloadPrompt_title=0x7f040002;
public static final int downloading_message=0x7f040007;
public static final int downloading_title=0x7f040006;
public static final int email_subject=0x7f040013;
public static final int email_to=0x7f040014;
public static final int errorString=0x7f040000;
public static final int extracting_message=0x7f040009;
public static final int extracting_title=0x7f040008;
public static final int go=0x7f04000d;
public static final int jump_dialog_title=0x7f04000b;
public static final int go=0x7f04000f;
public static final int hide_title=0x7f040017;
public static final int jump_dialog_title=0x7f04000d;
public static final int menu_about=0x7f04000b;
public static final int menu_jump=0x7f04000a;
public static final int page_hint=0x7f04000c;
public static final int menu_settings=0x7f04000c;
public static final int page_hint=0x7f04000e;
public static final int use_arabic_names=0x7f040016;
}
}
Binary file added res/drawable/about.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added res/drawable/jump.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added res/drawable/settings.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
43 changes: 43 additions & 0 deletions res/layout/about_us.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical" android:layout_width="fill_parent"
android:layout_height="fill_parent" android:background="@drawable/list">

<LinearLayout android:id="@+id/linear"
android:layout_width="fill_parent" android:layout_height="wrap_content"
android:orientation="vertical">
<TextView android:layout_width="fill_parent"
android:layout_height="fill_parent" android:visibility="visible"
android:textAppearance="?android:attr/textAppearanceSmall"
android:textColor="#FFFFFF" android:textStyle="bold" android:id="@+id/txtAbout"
android:singleLine="false" android:scrollbarAlwaysDrawVerticalTrack="true"
android:scrollbars="vertical" android:maxLines="16" android:text="@string/aboutUs"
android:padding="10dip" android:lineSpacingExtra="4dip" />
<TextView android:layout_width="fill_parent"
android:layout_height="wrap_content" android:visibility="visible"
android:textAppearance="?android:attr/textAppearanceSmall"
android:textStyle="bold" android:id="@+id/txtSupport"
android:singleLine="false" android:textColor="#CCCCCC" android:text="" />

</LinearLayout>
<TextView android:layout_width="fill_parent"
android:layout_height="wrap_content" android:linksClickable="true"
android:id="@+id/txtDevelopedBy" android:text="@string/developedBy"
android:textSize="12dip" android:layout_alignParentBottom="true"
android:textColor="#FFFFFF" android:paddingLeft="10dip" />

<TextView android:layout_width="fill_parent"
android:layout_height="wrap_content" android:linksClickable="true"
android:id="@+id/txtCopyRights" android:text="@string/copyRights"
android:textSize="12dip" android:layout_above="@id/txtDevelopedBy"
android:textColor="#FFFFFF" android:paddingLeft="10dip" />
<Button android:layout_width="300dip" android:layout_height="wrap_content"
android:id="@+id/btnAboutBack" android:text="Back"
android:layout_centerHorizontal="true" android:layout_above="@id/txtCopyRights"
android:visibility="visible" />
<Button android:layout_width="300dip" android:layout_height="wrap_content"
android:id="@+id/btnEmailUs" android:text="Email Quran Android"
android:layout_centerHorizontal="true" android:layout_above="@id/btnAboutBack"
android:visibility="visible" />

</RelativeLayout>
17 changes: 17 additions & 0 deletions res/layout/settings.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:background="@drawable/list"
>
<CheckBox android:id="@+id/chkArbaicNames"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/use_arabic_names" />

<CheckBox android:id="@+id/chkHideTitle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/hide_title" />
</LinearLayout>
13 changes: 13 additions & 0 deletions res/menu/option_menu.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<?xml version="1.0" encoding="utf-8"?>
<menu xmlns:android="http://schemas.android.com/apk/res/android">

<item android:id="@+id/menu_item_jump"
android:icon="@drawable/jump" android:title="@string/menu_jump"/>

<item android:id="@+id/menu_item_about_us"
android:icon="@drawable/about" android:title="@string/menu_about"/>

<item android:id="@+id/menu_item_settings"
android:icon="@drawable/settings" android:title="@string/menu_settings"/>

</menu>
48 changes: 31 additions & 17 deletions res/values/strings.xml
Original file line number Diff line number Diff line change
@@ -1,20 +1,34 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="errorString">Could not download Quran Pages!</string>
<string name="app_name">Quran</string>
<string name="downloadPrompt_title">Download Required Files?</string>
<string name="downloadPrompt">For optimal performance, some files must be downloaded to the sd card.
If you choose not to do this now, each page will take significantly longer to load. Would you
like to download the required files now?</string>
<string name="downloadPrompt_ok">Yes</string>
<string name="downloadPrompt_no">No</string>
<string name="downloading_title">Downloading...</string>
<string name="downloading_message">Please wait for the files to download.</string>
<string name="extracting_title">Processing...</string>
<string name="extracting_message">Please wait the files are processed.</string>
<string name="menu_jump">Jump</string>
<string name="jump_dialog_title">Jump To Page</string>
<string name="page_hint">Page Number</string>
<string name="go">Go</string>
<string name="cancel">Cancel</string>
<string name="errorString">Could not download Quran Pages!</string>
<string name="app_name">Quran Android</string>
<string name="downloadPrompt_title">Download Required Files?</string>
<string name="downloadPrompt">For optimal performance, some files must be
downloaded to the sd card.
If you choose not to do this now, each page will take significantly
longer to load. Would you
like to download the required files now?</string>
<string name="downloadPrompt_ok">Yes</string>
<string name="downloadPrompt_no">No</string>
<string name="downloading_title">Downloading...</string>
<string name="downloading_message">Please wait for the files to download.</string>
<string name="extracting_title">Processing...</string>
<string name="extracting_message">Please wait the files are processed.</string>
<string name="menu_jump">Jump</string>
<string name="menu_about">About Us</string>
<string name="menu_settings">Settings</string>
<string name="jump_dialog_title">Jump To Page</string>
<string name="page_hint">Page Number</string>
<string name="go">Go</string>
<string name="cancel">Cancel</string>
<string name="developedBy">Quran Android - Muslim Developers</string>
<string name="copyRights">Copy Rights - All Muslims</string>
<string name="email_subject">Feedback</string>
<string name="email_to">[email protected]</string>
<string name="aboutUs">Quran Android is a free, open source Quran
application for Android.\nUpcoming features include:\n- Bookmarks.\n-
Translations.\n- Search.\n- And more..\n\nLa tansawna men saleh el
doaa.</string>
<string name="use_arabic_names">Use arabic names</string>
<string name="hide_title">Full Screen Mode.\nHave a larger view area for pages.</string>
</resources>
61 changes: 61 additions & 0 deletions src/com/quran/labs/androidquran/AboutUsActivity.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
package com.quran.labs.androidquran;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.text.method.ScrollingMovementMethod;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;
import android.widget.TextView;

public class AboutUsActivity extends Activity implements OnClickListener {
protected Button btnBack;
protected Button btnEmailUs;
protected TextView txtDevelopedBy;
protected TextView txtCopyRights;
protected TextView txtAbout;

public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.about_us);
btnBack = (Button)findViewById(R.id.btnAboutBack);
btnBack.setOnClickListener(this);

btnEmailUs = (Button)findViewById(R.id.btnEmailUs);
btnEmailUs.setOnClickListener(this);

txtDevelopedBy = (TextView)findViewById(R.id.txtDevelopedBy);
txtDevelopedBy.setOnClickListener(this);

txtCopyRights = (TextView)findViewById(R.id.txtCopyRights);
txtCopyRights.setOnClickListener(this);

txtAbout = (TextView)findViewById(R.id.txtAbout);
txtAbout.setMovementMethod(new ScrollingMovementMethod());

if (getWindowManager().getDefaultDisplay().getHeight() <
getWindowManager().getDefaultDisplay().getWidth())
txtAbout.setMaxLines(6);
else
txtAbout.setMaxLines(16);
}

@Override
public void onClick(View v) {
switch (v.getId()) {
case R.id.btnAboutBack:
finish();
break;
case R.id.btnEmailUs:
final Intent emailIntent = new Intent(android.content.Intent.ACTION_SEND);
emailIntent.setType("plain/text");
emailIntent.putExtra(android.content.Intent.EXTRA_SUBJECT, getString(R.string.email_subject));
emailIntent.putExtra(android.content.Intent.EXTRA_EMAIL, new String[]{getString(R.string.email_to)});
startActivity(Intent.createChooser(emailIntent, "Send mail..."));
break;
default:
break;
}
}
}
Loading

0 comments on commit 7bea783

Please sign in to comment.