how to put all permissions to xml - Zooper Widget General

is it possible to put some advanced permissions to an xml file.
i found a lot of xml examples only for weather icon-sets.
here is my Test:
i want to change pictures per hour
in ZW it looks like this
$#DH#=10?/storage/emulated/0/LtriX/10.png$
$#DH#=11?/storage/emulated/0/LtriX/11.png$
........
for XML i try to do this:
<?xml version="1.0" encoding="utf-8"?>
<config>
<title>Test</title>
<description>change picture</description>
<icons>icons</icons>
<demo>0.png</demo>
<default>0.png</default>
<mode value="#DH#">Time</mode>
<condition>
<test>#DH#=10</test>
<image>10.png</image>
</condition>
<condition>
<test>#DH#=11</test>
<image>11.png</image>
</condition>
</config>
BUT this is not working
Zooper didnt shows my zip file
is there a solution......?

No solutions..?
_____________
LtriX

Related

[Q] Dialer font color - where?

I want to change the color font in the phone keypad.
Decompile htcdialer (apktool) but I can not find section where to declare this color.
I have black, I want white....
Anyone knows where it changes?
Help
Oki ... i find section:
styles.xml
<?xml version="1.0" encoding="UTF-8"?>
<resources>
<style name="text_style_dialer_button_number">
<item name="android:textSize">27.0sp</item>
<item name="android:textColor">@color/color_255_255_255</item> === (was 0 0 0)
but apktool shows errors:
DEcompilation:
http://www.youtube.com/watch?v=V6KPpl389qk
Compilation:
http://www.youtube.com/watch?v=Xf5dNPujyYQ
orginal APK file is here:
http://hotfile.com/dl/112060127/881b...ialer.apk.html
1. decompile and compile the same file (no change) and again shows errors...
WHY?
2. Why go to 1.apk in framework folder ??? (screen)
3. what should be in this folder?
As I wrote you via PM, it is not enough to change that value, there are 3 and you also need to adjust the shadow colors. Compilation errors are due to using a themed apk, compile with stock and then insert your needed png`s. You also need to adjust button and dialer icon colors.
No .... stock file generated the same errors. :/
look:
http://hotfile.com/dl/112066339/865f241/HtcDialer.apk.html
This is stock file. Try decompile and you see erros :/
This file extract of Gingerbread ([ROM] Android Revolution HD 4.0 β 4)
draxterix said:
Oki ... i find section:
styles.xml
<?xml version="1.0" encoding="UTF-8"?>
<resources>
<style name="text_style_dialer_button_number">
<item name="android:textSize">27.0sp</item>
<item name="android:textColor">@color/color_255_255_255</item> === (was 0 0 0)
but apktool shows errors:
DEcompilation:
http://www.youtube.com/watch?v=V6KPpl389qk
Compilation:
http://www.youtube.com/watch?v=Xf5dNPujyYQ
orginal APK file is here:
http://hotfile.com/dl/112060127/881b...ialer.apk.html
1. decompile and compile the same file (no change) and again shows errors...
WHY?
2. Why go to 1.apk in framework folder ??? (screen)
3. what should be in this folder?
Click to expand...
Click to collapse
For starters you are editing the wrong styles.xml file. The DHD you need to edit the styles.xml in /values-hdpi
My guess is you don't have the supported framework and that you are not editing a stock untouched .apk. I can't see your error messages from your youtube video.

[ Q / DEV ] Modifying Home.apk but not run after change

I want to change Home.apk from xHDPI 6x4 to 5x4.
After unpack Home.apk, I change in res\values-xhdpi\integers.xml
From
Code:
<?xml version="1.0" encoding="utf-8"?>
<resources>
<integer name="apptray_grid_rows">[B]6[/B]</integer>
<integer name="apptray_grid_cols">4</integer>
</resources>
To
Code:
<?xml version="1.0" encoding="utf-8"?>
<resources>
<integer name="apptray_grid_rows">[B]5[/B]</integer>
<integer name="apptray_grid_cols">4</integer>
</resources>
And repack Home.apk by Apktool
But after replace new Home.apk, it not working (everything ok but not show home launcher, black sreen). Please help me, thanks!:crying:
my old home.apk

Customize and create your own dynamic icons

PART 1
STEP 1
Dimensioning Your Icons
There are many Software for this you can go for gimp, photoshop, illustrator and many more.
I prefer photoshop.
You can download or purcase from Adobe Store.
Icon size: 136 x 136 (pixels)
STEP 2
Adding layer styles.
Playing with Bleending option.
Add your design your settings add beveal, drop shadow and much more.
IMPORTING ICONS TO MIUI THEME EDITOR
STEP : 1
Now the First thing to DO is Extract the zip file.
STEP : 2
Now GO to MIUI Themes Editor and launch it.
There are two ways of getting started up.
Either select a Theme and Edit or start a new project
STEP : 3
Starting Up a New Project.
[Note: Click on the picture for Enlarging]
STEP : 4
Click on File > New Theme
STEP : 5
Specify a name and Location.
STEP : 6
Later Adding
Theme Name
Author
Designer
Version
PART TWO [ IMPORTANT ]
This is how you reach a fancy icons they are noting but icons with Gif kind of animation we call them dynamic
So what's so special about them ?
Heh!!
You need to know som XML tricks like i am going to show you and i will even share my files which you can edit.
So the above metioned picture is an example how to place it.
FOR CALENDAR
Icons
| __ fancy_icons
|__ com.android.calendar
manifest.xml should be place inside the folders with pngs files
<?xml version="1.0" encoding="utf-8"?>
<!-- calendar -->
<Icon version="1" frameRate="0" width="136" height="136" screenWidth="720" useVariableUpdater="DateTime.Day">
<VariableBinders>
<BroadcastBinder action="android.intent.action.TIME_SET" />
<BroadcastBinder action="android.intent.action.DATE_CHANGED" />
</VariableBinders>
<Group pivotX="68" pivotY="68">
<Image x="68" y="68" align="center" alignV="center" src="date.png" srcid="#date" />
</Group>
</Icon>
You need to edit them accordingly like i have thepng files settled inside the folder com.android.calendar
For Rotational ICONS
<?xml version="1.0" encoding="utf-8"?>
<!-- Audio -->
<Icon version="1" frameRate="30" width="192" height="192" screenWidth="1080" >
<Image x="96" y="96" align="center" alignV="center" src="icon_bg.png" />
<Image x="96" y="96" align="center" alignV="center" centerX="59" centerY="59" src="gear.png" >
<RotationAnimation>
<Rotation angle="0" time="0"/>
<Rotation angle="360" time="10000"/>
</RotationAnimation>
</Image>
</Icon>
And place the Two icons inside the subfolders.
Source : http://en.miui.com/thread-76404-1-1.html
Credits to the OP.

Customize and create your own dynamic icons

PART 1
STEP 1
Dimensioning Your Icons
There are many Software for this you can go for gimp, photoshop, illustrator and many more.
I prefer photoshop.
You can download or purcase from Adobe Store.
Icon size: 136 x 136 (pixels)
STEP 2
Adding layer styles.
Playing with Bleending option.
Add your design your settings add beveal, drop shadow and much more.
IMPORTING ICONS TO MIUI THEME EDITOR
STEP : 1
Now the First thing to DO is Extract the zip file.
STEP : 2
Now GO to MIUI Themes Editor and launch it.
There are two ways of getting started up.
Either select a Theme and Edit or start a new project
STEP : 3
Starting Up a New Project.
[Note: Click on the picture for Enlarging]
STEP : 4
Click on File > New Theme
STEP : 5
Specify a name and Location.
STEP : 6
Later Adding
Theme Name
Author
Designer
Version
PART TWO [ IMPORTANT ]
This is how you reach a fancy icons they are noting but icons with Gif kind of animation we call them dynamic
So what's so special about them ?
Heh!!
You need to know som XML tricks like i am going to show you and i will even share my files which you can edit.
So the above metioned picture is an example how to place it.
FOR CALENDAR
Icons
| __ fancy_icons
|__ com.android.calendar
manifest.xml should be place inside the folders with pngs files
<?xml version="1.0" encoding="utf-8"?>
<!-- calendar -->
<Icon version="1" frameRate="0" width="136" height="136" screenWidth="720" useVariableUpdater="DateTime.Day">
<VariableBinders>
<BroadcastBinder action="android.intent.action.TIME_SET" />
<BroadcastBinder action="android.intent.action.DATE_CHANGED" />
</VariableBinders>
<Group pivotX="68" pivotY="68">
<Image x="68" y="68" align="center" alignV="center" src="date.png" srcid="#date" />
</Group>
</Icon>
You need to edit them accordingly like i have thepng files settled inside the folder com.android.calendar
For Rotational ICONS
<?xml version="1.0" encoding="utf-8"?>
<!-- Audio -->
<Icon version="1" frameRate="30" width="192" height="192" screenWidth="1080" >
<Image x="96" y="96" align="center" alignV="center" src="icon_bg.png" />
<Image x="96" y="96" align="center" alignV="center" centerX="59" centerY="59" src="gear.png" >
<RotationAnimation>
<Rotation angle="0" time="0"/>
<Rotation angle="360" time="10000"/>
</RotationAnimation>
</Image>
</Icon>
And place the Two icons inside the subfolders.

[Guide] Make your own watch faces [23-1-2015]

Hello everyone, I've made a simplified tutorial to make your own watchface widget.
In this update I made simpler source code that simplified some steps.
Thanks to xda for posting it in xda Portal
Requirements:
-Eclipse
-Android SDK
-Sony Add-on SDK
Click to expand...
Click to collapse
-----------------------------------------------------------------------------------------------------------------------
-----------------------------------------------------------------------------------------------------------------------​
1-Download the samples.
2-Extract the zip.
3-Copy the both extracted folders to: "android-sdks\add-ons\addon-sony_add-on_sdk_3_0-sony-19\samples\SmartExtensions".
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
4-Open Eclipse and press Ctrl+N, open "Android" and choose "Android Sample Project".
5-Choose "Sony Add-on SDK 3.0".
6-Choose "SmartExtensions > SmartExtensionAPI" and press Finish.
7-Repeat step 4 to 5, choose "SmartExtensions > SmartExtensionUtils" and press Finish.
8-Repeat step 4 to 5, choose "SmartExtensions > ClockWidgetAnalog" if you wanna make an analog clock. or "SmartExtensions > ClockWidgetDigitalList" if you need to make a digital clock. For example, I'll choose the analog clock.
9-Press Finish
10-Now your workspace should looks like this:
11-To rename the project right click on it like this image:
12-Give it any name you want
13-To rename application package right click like this image:
14-Go to: res/values/strings.xml
15-Change these strings and press Ctrl+S to save it.
-You can keep the 'more apps" link if you want. It go to the watch faces collection thread.
-It's optional to add your email, and here's how to remove "Contact me" button:
-Go to res/layout/activity_preference.xml and find this:
Code:
<Button
android:id="@+id/emailBtn"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:visibility="[COLOR="Red"]visible[/COLOR]"
android:text="@string/email_btn"/>
-Then change the text marked with red above to "gone". So it will be like this:
Code:
<Button
android:id="@+id/emailBtn"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:visibility="[COLOR="Red"]gone[/COLOR]"
android:text="@string/email_btn"/>
16-Change the graphical resources change files in res/drawable-nodpi
17-Connect you device to the pc
18-Enable USB debugging on your phone
19-Right click on the project > Run As > Android application
20-If you want to share the apk you'll find it in the project bin
21-Enjoy
-----------------------------------------------------------------------------------------------------------------------​
How To Resize:
1-Go to "AnalogClock.java" or "DigitalClockLevelList.java in src/-package name-.widgets
2-Edit the marked in red below:
Code:
@Override
public int getWidth() {
return getCellWidth() * [COLOR="Red"]5[/COLOR];
}
@Override
public int getHeight() {
return getCellHeight() * [COLOR="Red"]5[/COLOR];
}
-----------------------------------------------------------------------------------------------------------------------​
How To Add Date:
1-Create new xml file in "res/layout" and give it any name you want
2-Add this:
Code:
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:widgets="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:weightSum="1" >
[COLOR="RoyalBlue"]<com.sonyericsson.extras.liveware.aef.widget.TimeLayout[/COLOR]
android:layout_width="wrap_content"
android:layout_height="wrap_content" >
<com.sonyericsson.extras.liveware.aef.widget.TimeView
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:gravity="center"
android:includeFontPadding="false"
android:textColor="[COLOR="DarkOrange"]@android:color/white[/COLOR]"
widgets:textSize="[COLOR="Lime"]25[/COLOR]px"
widgets:timeType="[COLOR="Red"]days_of_month[/COLOR]" />
</com.sonyericsson.extras.liveware.aef.widget.TimeLayout>
</RelativeLayout>
3-You can change the text marked in red above to:
-"days_of_week"
-"days_of_month"
-"days_of_year"
-"months"
4-You can change the number marked in green above to any number you want, to set the font size. Please notice that the unit must be "px" and do not use "dp".
5-You can change on the text marked in orange "white" to "black", or you can remove all the text in orange and put any hex color code. For example:
android:textColor="#ffbf00"
6-To change the position of it, add under "<com.sonyericsson.extras.liveware.aef.widget.TimeLayout" which is marked in blue above:
-android:layout_centerInParent="true" to put it in the center.
-android:layout_centerHorizontal="true" to put it center in horizontal.
-android:layout_centerVertical="true" to put it center in vertical.
-android:layout_alignParentRight="true" to move it to right side.
-android:layout_alignParentLeft="true" to move it to left side.
-android:layout_alignParentTop="true" to move it to to the top.
-android:layout_alignParentBottom="true" to move it to the buttom.
-android:layout_marginRight="10px" change "10" to any number.
-android:layout_marginLeft="10px" change "10" to any number.
-android:layout_marginTop="10px" change "10" to any number.
-android:layout_marginBotton="10px" change "10" to any number.
7-At last, we must include the date xml on the main watch layout xml which is called on my samples "clock_widget_analog.xml" on analog and "clock_widget_levellists.xml" on the digital clock. For example, if you named the xml you made "date.xml" we will add the text marked in red below:
Code:
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:widgets="http://schemas.android.com/apk/res-auto"
xmlns:app="http://schemas.android.com/apk/res/com.sonymobile.smartconnect.extension.testclock"
android:layout_width="215px"
android:layout_height="170px"
android:background="@android:color/transparent"
android:baselineAligned="false" >
<ImageView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:src="@drawable/watchface_bg" />
[COLOR="Red"]<include layout="@layout/date" />[/COLOR]
<include layout="@layout/analog_clock_hand_hours_border" />
<include layout="@layout/analog_clock_hand_minutes_border" />
<include layout="@layout/analog_clock_hand_seconds" />
</RelativeLayout>
-----------------------------------------------------------------------------------------------------------------------​
How To Reorder:
1-Open the main layout xml, -"clock_widget_analog.xml" on analog and "clock_widget_levellists.xml" on the digital clock-. For example, I'll work on analog.
2-You can remove text that start with "<!--" and end with "-->" like the marked in red . it's just notes from sony.This will make it easier:
Code:
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:widgets="http://schemas.android.com/apk/res-auto"
xmlns:app="http://schemas.android.com/apk/res/com.sonymobile.smartconnect.extension.testclock"
android:layout_width="215px"
android:layout_height="170px"
android:background="@android:color/transparent"
android:baselineAligned="false" >
<!-- We set a background on containing the base for a watch face. -->
<ImageView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:src="@drawable/watchface_bg" />
[COLOR="Red"]<!-- Here we reference a TimeLayout using a single drawable for displaying
the hour hand. -->[/COLOR]
<include layout="@layout/analog_clock_hand_hours_border" />
[COLOR="Red"]<!-- Here we reference a TimeLayout using a single drawable for displaying
the minute hand. -->[/COLOR]
<include layout="@layout/analog_clock_hand_minutes_border" />
[COLOR="Red"]<!-- Here we reference a TimeLayout using a single drawable for displaying
the second hand. Note: Seconds will not be shown when the backlight is off
on the SmartWatch 2. -->[/COLOR]
<include layout="@layout/analog_clock_hand_seconds" />
</RelativeLayout>
3-Now you can reorder lines that start with "<include layout="
-----------------------------------------------------------------------------------------------------------------------​
Multiple WatchFace In One App:
-First example is to add digital clock to analog:
1-Copy xml and png files in res/layout and res/drawable-nodpi from digital to analog
2-Copy "DigitalClockLevelList.java" on src/-package name-.widgets from digital to analog
3-Open "ClockWidgetRegistrationInformation" in src/-package name-/ and search for: WidgetClassList widgetList = new WidgetClassList();
4-Add this under WidgetClassList widgetList = new WidgetClassList();:
widgetList.add(DigitalClockLevelList.class);
The text marked in red is same file name you've copied in step 2
5-Now Eclipse will underline it in red as error, it will give you a list of fixes, choose first fix
-Second example if you want to make 2 or more analog watchfaces:
1-Go to res/layout and duplicate all except "activity_preferences.xml", you can rename the duplicated xmls for example by adding "2"
2-Duplicate "AnalogClock.java" in src/-package name-.widgets
3-Add graphical resources on res/drawable-nodpi/ and give it the same names but with "_2"
4-Add the following lines to res/values/strings.xml:
Code:
<string name="name_1">Analog 1</string>
<string name="name_2">Analog 2</string>
To be like this:
Code:
<?xml version="1.0" encoding="utf-8"?>
<!-- No translation of sample extensions -->
<resources xmlns:tools="http://schemas.android.com/tools" tools:ignore="MissingTranslation">
<string name="app_name">Analog clock widget</string>
<string name="preference_info">Analog clock watchface widget for Sony SmartWatch2\nDeveloped by Naheel Azawy\nVersion 1.0</string>
[COLOR="Red"]<string name="name_1">Analog 1</string>
<string name="name_2">Analog 2</string>[/COLOR]
</resources>
5-Edit "AnalogClock2.java" in src/-package name-.widgets from:
Code:
package com.naheel.sw2.widget.example.analog.widgets;
import com.naheel.sw2.widget.example.analog.R;
/**
* This widget displays an analog clock providing resources which will be
* automatically rotated by the accessory firmware to reflect the time.
*/
public class AnalogClock2 extends SmartWatch2ClockWidget {
public AnalogClock2(WidgetBundle widgetBundle) {
super(widgetBundle);
}
@Override
int getWidgetLayout() {
return R.layout.[COLOR="Red"]clock_widget_analog[/COLOR];
}
@Override
public int getName() {
return R.string.[COLOR="Red"]app_name[/COLOR];
}
@Override
public int getWidth() {
return getCellWidth() * 5;
}
@Override
public int getHeight() {
return getCellHeight() * 5;
}
@Override
public int getPreviewUri() {
return R.drawable.[COLOR="Red"]watchface_analog_preview[/COLOR];
}
}
To:
Code:
package com.naheel.sw2.widget.example.analog.widgets;
import com.naheel.sw2.widget.example.analog.R;
/**
* This widget displays an analog clock providing resources which will be
* automatically rotated by the accessory firmware to reflect the time.
*/
public class AnalogClock2 extends SmartWatch2ClockWidget {
public AnalogClock2(WidgetBundle widgetBundle) {
super(widgetBundle);
}
@Override
int getWidgetLayout() {
return R.layout.[COLOR="Red"]clock_widget_analog_2[/COLOR];
}
@Override
public int getName() {
return R.string.[COLOR="Red"]name_2[/COLOR];
}
@Override
public int getWidth() {
return getCellWidth() * 5;
}
@Override
public int getHeight() {
return getCellHeight() * 5;
}
@Override
public int getPreviewUri() {
return R.drawable.[COLOR="Red"]watchface_analog_preview_2[/COLOR];
}
}
6-Edit "clock_widget_analog_2.xml" on res/layout from:
Code:
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:widgets="http://schemas.android.com/apk/res-auto"
xmlns:app="http://schemas.android.com/apk/res/com.sonymobile.smartconnect.extension.testclock"
android:layout_width="215px"
android:layout_height="170px"
android:background="@android:color/transparent"
android:baselineAligned="false" >
<!-- We set a background on containing the base for a watch face. -->
<ImageView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:src="@drawable/[COLOR="Red"]watchface_bg[/COLOR]" />
<!-- Here we reference a TimeLayout using a single drawable for displaying
the hour hand. -->
<include layout="@layout/[COLOR="Red"]analog_clock_hand_hours_border[/COLOR]" />
<!-- Here we reference a TimeLayout using a single drawable for displaying
the minute hand. -->
<include layout="@layout/[COLOR="Red"]analog_clock_hand_minutes_border[/COLOR]" />
<!-- Here we reference a TimeLayout using a single drawable for displaying
the second hand. Note: Seconds will not be shown when the backlight is off
on the SmartWatch 2. -->
<include layout="@layout/[COLOR="Red"]analog_clock_hand_seconds[/COLOR]" />
</RelativeLayout>
To:
Code:
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:widgets="http://schemas.android.com/apk/res-auto"
xmlns:app="http://schemas.android.com/apk/res/com.sonymobile.smartconnect.extension.testclock"
android:layout_width="215px"
android:layout_height="170px"
android:background="@android:color/transparent"
android:baselineAligned="false" >
<!-- We set a background on containing the base for a watch face. -->
<ImageView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:src="@drawable/[COLOR="Red"]watchface_bg_2[/COLOR]" />
<!-- Here we reference a TimeLayout using a single drawable for displaying
the hour hand. -->
<include layout="@layout/[COLOR="Red"]analog_clock_hand_hours_border_2[/COLOR]" />
<!-- Here we reference a TimeLayout using a single drawable for displaying
the minute hand. -->
<include layout="@layout/[COLOR="Red"]analog_clock_hand_minutes_border_2[/COLOR]" />
<!-- Here we reference a TimeLayout using a single drawable for displaying
the second hand. Note: Seconds will not be shown when the backlight is off
on the SmartWatch 2. -->
<include layout="@layout/[COLOR="Red"]analog_clock_hand_seconds_2[/COLOR]" />
</RelativeLayout>
7-Edit "analog_clock_hand_seconds_2.xml" from:
Code:
<?xml version="1.0" encoding="utf-8"?>
<!-- Use TimeLayout components to place TimeViews showing e.g. hours or minutes
when building up the UI. -->
<com.sonyericsson.extras.liveware.aef.widget.TimeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:widgets="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@android:color/transparent"
widgets:gravity="center" >
<!-- Defines a second hand using a drawable and setting the timeType to
seconds. The second hand will be automatically rotated by the accessory
firmware. Note: Seconds will not be shown when the backlight is off
on the SmartWatch 2. -->
<com.sonyericsson.extras.liveware.aef.widget.TimeView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@drawable/[COLOR="Red"]second_00[/COLOR]"
widgets:timeType="seconds" />
</com.sonyericsson.extras.liveware.aef.widget.TimeLayout>
To:
Code:
<?xml version="1.0" encoding="utf-8"?>
<!-- Use TimeLayout components to place TimeViews showing e.g. hours or minutes
when building up the UI. -->
<com.sonyericsson.extras.liveware.aef.widget.TimeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:widgets="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@android:color/transparent"
widgets:gravity="center" >
<!-- Defines a second hand using a drawable and setting the timeType to
seconds. The second hand will be automatically rotated by the accessory
firmware. Note: Seconds will not be shown when the backlight is off
on the SmartWatch 2. -->
<com.sonyericsson.extras.liveware.aef.widget.TimeView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@drawable/[COLOR="Red"]second_00_2[/COLOR]"
widgets:timeType="seconds" />
</com.sonyericsson.extras.liveware.aef.widget.TimeLayout>
8-Edit "analog_clock_hand_minutes_border_2.xml" from:
Code:
<?xml version="1.0" encoding="utf-8"?>
<!-- Use TimeLayout components to place TimeViews showing e.g. hours or minutes
when building up the UI. -->
<com.sonyericsson.extras.liveware.aef.widget.TimeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:widgets="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@android:color/transparent"
widgets:gravity="center" >
<!-- Defines a minute hand using a drawable and setting the timeType to
minutes. The minute hand will be automatically rotated by the accessory
firmware. -->
<com.sonyericsson.extras.liveware.aef.widget.TimeView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@drawable/[COLOR="Red"]minute_border_00[/COLOR]"
widgets:timeType="minutes" />
</com.sonyericsson.extras.liveware.aef.widget.TimeLayout>
To:
Code:
<?xml version="1.0" encoding="utf-8"?>
<!-- Use TimeLayout components to place TimeViews showing e.g. hours or minutes
when building up the UI. -->
<com.sonyericsson.extras.liveware.aef.widget.TimeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:widgets="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@android:color/transparent"
widgets:gravity="center" >
<!-- Defines a minute hand using a drawable and setting the timeType to
minutes. The minute hand will be automatically rotated by the accessory
firmware. -->
<com.sonyericsson.extras.liveware.aef.widget.TimeView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@drawable/[COLOR="Red"]minute_border_00_2[/COLOR]"
widgets:timeType="minutes" />
</com.sonyericsson.extras.liveware.aef.widget.TimeLayout>
9-Edit "analog_clock_hand_hours_border_2.xml" from:
Code:
<?xml version="1.0" encoding="utf-8"?>
<!-- Use TimeLayout components to place TimeViews showing e.g. hours or minutes
when building up the UI. -->
<com.sonyericsson.extras.liveware.aef.widget.TimeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:widgets="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@android:color/transparent"
widgets:gravity="center" >
<!-- Defines an hour hand using a drawable and setting the timeType to
hours_fine. The hour hand will be automatically rotated by the accessory
firmware. -->
<com.sonyericsson.extras.liveware.aef.widget.TimeView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@drawable/[COLOR="Red"]hour_border_00[/COLOR]"
widgets:timeType="hours_fine" />
</com.sonyericsson.extras.liveware.aef.widget.TimeLayout>
To:
Code:
<?xml version="1.0" encoding="utf-8"?>
<!-- Use TimeLayout components to place TimeViews showing e.g. hours or minutes
when building up the UI. -->
<com.sonyericsson.extras.liveware.aef.widget.TimeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:widgets="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@android:color/transparent"
widgets:gravity="center" >
<!-- Defines an hour hand using a drawable and setting the timeType to
hours_fine. The hour hand will be automatically rotated by the accessory
firmware. -->
<com.sonyericsson.extras.liveware.aef.widget.TimeView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@drawable/[COLOR="Red"]hour_border_00_2[/COLOR]"
widgets:timeType="hours_fine" />
</com.sonyericsson.extras.liveware.aef.widget.TimeLayout>
-----------------------------------------------------------------------------------------------------------------------
---Old thread---
-----------------------------------------------------------------------------------------------------------------------
Please do not take everything and say it's you'r own job. It's enough to say thanks to me on your app. There's something in this world called google removal
Click to expand...
Click to collapse
If you made a watch, post it here and I'll add it to the collection​
Hello,
Thank you very much for your Tutorial. I got my own analog clock.
But is there any way to have a background for Digital Clock?
8-Edit "analog_clock_hand_minutes_border_2.xml" from
dont have analog_clock_hand_minutes_border_2.xml !
---------- Post added at 02:53 PM ---------- Previous post was at 02:47 PM ----------
my watch faces
Hi,
Is it still possible to create new watch faces for the SW2 these days? The main obstacle to start seems to be the inability to download the Sony Add-on SDK. I have only been able to find version 1.0 so far with much searching. Does anyone know where the version 3 file can be downloaded?
Thanks,
Lee

Categories

Resources