Skip to content

Commit

Permalink
Initial checkin
Browse files Browse the repository at this point in the history
  • Loading branch information
sergedesmedt committed Nov 28, 2012
1 parent bb7c8a3 commit e243612
Show file tree
Hide file tree
Showing 45 changed files with 2,164 additions and 84 deletions.
36 changes: 36 additions & 0 deletions YetAnotherDrawableDemo/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,42 @@
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity android:name=".CustomDrawableFromXMLActivity">
</activity>
<activity android:name="CustomDrawableFromXMLConfigActivity">
</activity>
<activity android:name=".CustomDrawableActivity">
</activity>
<activity android:name=".CustomDrawableConfigActivity">
</activity>
<activity android:name="CustomDrawableMatrixTransformationActivity">
</activity>
<activity android:name="CustomDrawableMatrixTransformationConfigActivity">
</activity>
<activity android:name="MatrixTransformationTypeSelectorActivity">
</activity>
<activity android:name="MatrixTransformationRotateConfigActivity">
</activity>
<activity android:name="MatrixTransformationScaleConfigActivity">
</activity>
<activity android:name="MatrixTransformationSkewConfigActivity">
</activity>
<activity android:name="MatrixTransformationTranslateConfigActivity">
</activity>
<activity android:name="CustomDrawableCameraTransformationActivity">
</activity>
<activity android:name="CustomDrawableCameraTransformationConfigActivity">
</activity>
<activity android:name="CameraTransformationTypeSelectorActivity">
</activity>
<activity android:name="CameraTransformationRotateXConfigActivity">
</activity>
<activity android:name="CameraTransformationRotateYConfigActivity">
</activity>
<activity android:name="CameraTransformationRotateZConfigActivity">
</activity>
<activity android:name="CameraTransformationTranslateConfigActivity">
</activity>

</application>
</manifest>
2 changes: 2 additions & 0 deletions YetAnotherDrawableDemo/default.properties
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,5 @@

# Project target.
target=android-10
android.library.reference.1=..\\YetAnotherDrawableDemoLib
android.library.reference.2=../YetAnotherDrawableDemoApp
5 changes: 5 additions & 0 deletions YetAnotherDrawableDemo/res/drawable/line_drawable.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="line">
<solid android:color="#00ff0000"/>
<stroke android:width="2px" android:color="#ffffff" />
</shape>
4 changes: 2 additions & 2 deletions YetAnotherDrawableDemo/res/drawable/oval_drawable.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="rectangle">
<solid android:color="#00ff0000"/>
<shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="oval">
<stroke android:width="2px" android:color="#ffffff" />
<solid android:color="#ffffd300"/>
</shape>
5 changes: 5 additions & 0 deletions YetAnotherDrawableDemo/res/drawable/rectangle_drawable.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="rectangle">
<stroke android:width="2px" android:color="#ffffff" />
<solid android:color="#ffffd300"/>
</shape>
18 changes: 18 additions & 0 deletions YetAnotherDrawableDemo/res/drawable/ring_drawable.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:useLevel="false"
android:shape="ring"
android:innerRadiusRatio="3"
android:thicknessRatio="8"
>
<stroke android:width="2px" android:color="#ffffff" />
<solid android:color="#ffffd300"/>
<size android:width="48dip"
android:height="48dip" />
<!--<gradient android:type="sweep"
android:useLevel="false"
android:startColor="#4c737373"
android:centerColor="#4c737373"
android:centerY="0.50"
android:endColor="#ffffd300" />-->
</shape>
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent">
<Button
android:id="@+id/addBtn"
android:text="Add New Transform"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:onClick="addItems"/>
<CheckBox android:text="Translate to center" android:id="@+id/checkBoxCamTranslateToCenter" android:layout_width="wrap_content" android:layout_height="wrap_content"></CheckBox>
<CheckBox android:text="Oval out transform" android:id="@+id/checkBoxCamOvalOutTransform" android:layout_width="wrap_content" android:layout_height="wrap_content"></CheckBox>
<ListView
android:id="@android:id/list"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:drawSelectorOnTop="false"
/>
</LinearLayout>
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent">
<TextView android:layout_width="wrap_content" android:id="@+id/textView2" android:layout_height="wrap_content" android:text="angle" android:textAppearance="?android:attr/textAppearanceLarge"></TextView>
<EditText android:layout_width="match_parent" android:layout_height="wrap_content" android:id="@+id/editAngleX" android:inputType="numberSigned">
<requestFocus></requestFocus>
</EditText>
</LinearLayout>

Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent">
<TextView android:layout_width="wrap_content" android:id="@+id/textView2" android:layout_height="wrap_content" android:text="angle" android:textAppearance="?android:attr/textAppearanceLarge"></TextView>
<EditText android:layout_width="match_parent" android:layout_height="wrap_content" android:id="@+id/editAngleY" android:inputType="numberSigned">
<requestFocus></requestFocus>
</EditText>
</LinearLayout>
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent">
<TextView android:layout_width="wrap_content" android:id="@+id/textView2" android:layout_height="wrap_content" android:text="angle" android:textAppearance="?android:attr/textAppearanceLarge"></TextView>
<EditText android:layout_width="match_parent" android:layout_height="wrap_content" android:id="@+id/editAngleZ" android:inputType="numberSigned">
<requestFocus></requestFocus>
</EditText>
</LinearLayout>
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent">
<TextView android:layout_width="wrap_content" android:id="@+id/textView2" android:layout_height="wrap_content" android:text="dX" android:textAppearance="?android:attr/textAppearanceLarge"></TextView>
<EditText android:layout_width="match_parent" android:layout_height="wrap_content" android:id="@+id/editCamDX" android:inputType="numberSigned">
<requestFocus></requestFocus>
</EditText>
<TextView android:layout_width="wrap_content" android:id="@+id/textView3" android:layout_height="wrap_content" android:text="dY" android:textAppearance="?android:attr/textAppearanceLarge"></TextView>
<EditText android:layout_width="match_parent" android:layout_height="wrap_content" android:id="@+id/editCamDY" android:inputType="numberSigned"></EditText>
<TextView android:layout_width="wrap_content" android:id="@+id/textView3" android:layout_height="wrap_content" android:text="dZ" android:textAppearance="?android:attr/textAppearanceLarge"></TextView>
<EditText android:layout_width="match_parent" android:layout_height="wrap_content" android:id="@+id/editCamDZ" android:inputType="numberSigned"></EditText>
</LinearLayout>
11 changes: 11 additions & 0 deletions YetAnotherDrawableDemo/res/layout/code_drawable_config.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent">
<CheckBox android:text="Draw rectangle" android:textAppearance="?android:attr/textAppearanceLarge" android:id="@+id/checkBoxInCodeDrawRectangle" android:layout_width="wrap_content" android:layout_height="wrap_content"></CheckBox>
<CheckBox android:text="Draw oval" android:textAppearance="?android:attr/textAppearanceLarge" android:id="@+id/checkBoxInCodeDrawOval" android:layout_width="wrap_content" android:layout_height="wrap_content"></CheckBox>
<CheckBox android:text="Draw arc" android:textAppearance="?android:attr/textAppearanceLarge" android:id="@+id/checkBoxInCodeDrawArc" android:layout_width="wrap_content" android:layout_height="wrap_content"></CheckBox>
<CheckBox android:text="Set bounds" android:textAppearance="?android:attr/textAppearanceLarge" android:id="@+id/checkBoxInCodeSetBounds" android:layout_width="wrap_content" android:layout_height="wrap_content"></CheckBox>
</LinearLayout>
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@drawable/rectangle_drawable">

</LinearLayout>
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
<?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" >
<Button
android:id="@+id/addBtn"
android:text="Add New Transform"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:onClick="addItems"/>
<CheckBox android:text="Translate to center" android:id="@+id/checkBoxTranslateToCenter" android:layout_width="wrap_content" android:layout_height="wrap_content"></CheckBox>
<CheckBox android:text="Oval out transform" android:id="@+id/checkBoxOvalOutTransform" android:layout_width="wrap_content" android:layout_height="wrap_content"></CheckBox>
<ListView
android:id="@android:id/list"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:drawSelectorOnTop="false"
/>
</LinearLayout>

Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent">
<TextView android:layout_width="wrap_content" android:id="@+id/textView1" android:layout_height="wrap_content" android:text="Type" android:textAppearance="?android:attr/textAppearanceMedium"></TextView>
<RadioGroup android:id="@+id/radioRotationOrder" android:layout_width="wrap_content" android:layout_height="wrap_content" >
<RadioButton android:text="Set" android:id="@+id/rbRotateTypeSet" android:layout_width="wrap_content" android:layout_height="wrap_content"></RadioButton>
<RadioButton android:text="Pre" android:id="@+id/rbRotateTypePre" android:layout_width="wrap_content" android:layout_height="wrap_content"></RadioButton>
<RadioButton android:text="Post" android:id="@+id/rbRotateTypePost" android:layout_width="wrap_content" android:layout_height="wrap_content"></RadioButton>
</RadioGroup>
<TextView android:layout_width="wrap_content" android:id="@+id/textView2" android:layout_height="wrap_content" android:text="angle" android:textAppearance="?android:attr/textAppearanceLarge"></TextView>
<EditText android:layout_width="match_parent" android:layout_height="wrap_content" android:id="@+id/editAngle" android:inputType="numberSigned">
<requestFocus></requestFocus>
</EditText>

</LinearLayout>
20 changes: 20 additions & 0 deletions YetAnotherDrawableDemo/res/layout/matrixtransform_scale_config.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent">
<TextView android:layout_width="wrap_content" android:id="@+id/textView1" android:layout_height="wrap_content" android:text="Type" android:textAppearance="?android:attr/textAppearanceMedium"></TextView>
<RadioGroup android:id="@+id/radioScaleOrder" android:layout_width="wrap_content" android:layout_height="wrap_content" >
<RadioButton android:text="Set" android:id="@+id/rbScaleTypeSet" android:layout_width="wrap_content" android:layout_height="wrap_content"></RadioButton>
<RadioButton android:text="Pre" android:id="@+id/rbScaleTypePre" android:layout_width="wrap_content" android:layout_height="wrap_content"></RadioButton>
<RadioButton android:text="Post" android:id="@+id/rbScaleTypePost" android:layout_width="wrap_content" android:layout_height="wrap_content"></RadioButton>
</RadioGroup>
<TextView android:layout_width="wrap_content" android:id="@+id/textView2" android:layout_height="wrap_content" android:text="sX" android:textAppearance="?android:attr/textAppearanceLarge"></TextView>
<EditText android:layout_width="match_parent" android:layout_height="wrap_content" android:id="@+id/editSX" android:inputType="numberSigned">
<requestFocus></requestFocus>
</EditText>
<TextView android:layout_width="wrap_content" android:id="@+id/textView3" android:layout_height="wrap_content" android:text="sY" android:textAppearance="?android:attr/textAppearanceLarge"></TextView>
<EditText android:layout_width="match_parent" android:layout_height="wrap_content" android:id="@+id/editSY" android:inputType="numberSigned"></EditText>

</LinearLayout>
20 changes: 20 additions & 0 deletions YetAnotherDrawableDemo/res/layout/matrixtransform_skew_config.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent">
<TextView android:layout_width="wrap_content" android:id="@+id/textView1" android:layout_height="wrap_content" android:text="Type" android:textAppearance="?android:attr/textAppearanceMedium"></TextView>
<RadioGroup android:id="@+id/radioSkewOrder" android:layout_width="wrap_content" android:layout_height="wrap_content" >
<RadioButton android:text="Set" android:id="@+id/rbSkewTypeSet" android:layout_width="wrap_content" android:layout_height="wrap_content"></RadioButton>
<RadioButton android:text="Pre" android:id="@+id/rbSkewTypePre" android:layout_width="wrap_content" android:layout_height="wrap_content"></RadioButton>
<RadioButton android:text="Post" android:id="@+id/rbSkewTypePost" android:layout_width="wrap_content" android:layout_height="wrap_content"></RadioButton>
</RadioGroup>
<TextView android:layout_width="wrap_content" android:id="@+id/textView2" android:layout_height="wrap_content" android:text="kX" android:textAppearance="?android:attr/textAppearanceLarge"></TextView>
<EditText android:layout_width="match_parent" android:layout_height="wrap_content" android:id="@+id/editKX" android:inputType="numberDecimal">
<requestFocus></requestFocus>
</EditText>
<TextView android:layout_width="wrap_content" android:id="@+id/textView3" android:layout_height="wrap_content" android:text="kY" android:textAppearance="?android:attr/textAppearanceLarge"></TextView>
<EditText android:layout_width="match_parent" android:layout_height="wrap_content" android:id="@+id/editKY" android:inputType="numberDecimal"></EditText>

</LinearLayout>
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent">
<TextView android:layout_width="wrap_content" android:id="@+id/textView1" android:layout_height="wrap_content" android:text="Type" android:textAppearance="?android:attr/textAppearanceMedium"></TextView>
<RadioGroup android:id="@+id/radioTranslateOrder" android:layout_width="wrap_content" android:layout_height="wrap_content" >
<RadioButton android:text="Set" android:id="@+id/rbTranslateTypeSet" android:layout_width="wrap_content" android:layout_height="wrap_content"></RadioButton>
<RadioButton android:text="Pre" android:id="@+id/rbTranslateTypePre" android:layout_width="wrap_content" android:layout_height="wrap_content"></RadioButton>
<RadioButton android:text="Post" android:id="@+id/rbTranslateTypePost" android:layout_width="wrap_content" android:layout_height="wrap_content"></RadioButton>
</RadioGroup>
<TextView android:layout_width="wrap_content" android:id="@+id/textView2" android:layout_height="wrap_content" android:text="dX" android:textAppearance="?android:attr/textAppearanceLarge"></TextView>
<EditText android:layout_width="match_parent" android:layout_height="wrap_content" android:id="@+id/editDX" android:inputType="numberSigned">
<requestFocus></requestFocus>
</EditText>
<TextView android:layout_width="wrap_content" android:id="@+id/textView3" android:layout_height="wrap_content" android:text="dY" android:textAppearance="?android:attr/textAppearanceLarge"></TextView>
<EditText android:layout_width="match_parent" android:layout_height="wrap_content" android:id="@+id/editDY" android:inputType="numberSigned"></EditText>

</LinearLayout>
15 changes: 15 additions & 0 deletions YetAnotherDrawableDemo/res/layout/xml_drawable_config.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent">
<CheckBox android:text="Draw rectangle" android:textAppearance="?android:attr/textAppearanceLarge" android:id="@+id/checkBoxInXMLDrawRectangle" android:layout_width="wrap_content" android:layout_height="wrap_content"></CheckBox>
<CheckBox android:text="Draw line" android:textAppearance="?android:attr/textAppearanceLarge" android:id="@+id/checkBoxInXMLDrawLine" android:layout_width="wrap_content" android:layout_height="wrap_content"></CheckBox>
<CheckBox android:text="Draw oval" android:textAppearance="?android:attr/textAppearanceLarge" android:id="@+id/checkBoxInXMLDrawOval" android:layout_width="wrap_content" android:layout_height="wrap_content"></CheckBox>
<CheckBox android:text="Draw ring" android:textAppearance="?android:attr/textAppearanceLarge" android:id="@+id/checkBoxInXMLDrawRing" android:layout_width="wrap_content" android:layout_height="wrap_content"></CheckBox>
<CheckBox android:text="Set bounds" android:textAppearance="?android:attr/textAppearanceLarge" android:id="@+id/checkBoxInXMLSetBounds" android:layout_width="wrap_content" android:layout_height="wrap_content"></CheckBox>
<CheckBox android:text="As ShapeDrawable" android:textAppearance="?android:attr/textAppearanceLarge" android:id="@+id/checkBoxInXMLAsShapeDrawable" android:layout_width="wrap_content" android:layout_height="wrap_content"></CheckBox>
<CheckBox android:text="As GradientDrawable" android:textAppearance="?android:attr/textAppearanceLarge" android:id="@+id/checkBoxInXMLAsGradientDrawable" android:layout_width="wrap_content" android:layout_height="wrap_content"></CheckBox>
</LinearLayout>

6 changes: 6 additions & 0 deletions YetAnotherDrawableDemo/res/menu/view_config.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<menu
xmlns:android="http://schemas.android.com/apk/res/android">
<item android:id="@+id/mnu_genericconfig"
android:title="@string/config"/>
</menu>
Loading

0 comments on commit e243612

Please sign in to comment.