Skip to content
This repository was archived by the owner on Sep 3, 2024. It is now read-only.

Commit 8dd58af

Browse files
committed
reformat code
1 parent 31cf1a4 commit 8dd58af

File tree

113 files changed

+2146
-1010
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

113 files changed

+2146
-1010
lines changed

app/src/main/AndroidManifest.xml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,12 @@
1414
android:value="SEP10" />
1515
<meta-data
1616
android:name="com.samsung.android.icon_container.has_icon_container"
17-
android:value="true"/>
17+
android:value="true" />
1818
<meta-data
1919
android:name="com.samsung.android.icon_container.feature_appicon"
20-
android:value="ADAPTIVEICON_SHADOW"/>
20+
android:value="ADAPTIVEICON_SHADOW" />
2121

22-
<activity
23-
android:name="de.dlyt.yanndroid.oneuiexample.SwitchBarActivity" />
22+
<activity android:name="de.dlyt.yanndroid.oneuiexample.SwitchBarActivity" />
2423
<activity
2524
android:name="de.dlyt.yanndroid.oneuiexample.AboutActivity"
2625
android:theme="@style/OneUIAboutTheme" />

app/src/main/java/de/dlyt/yanndroid/oneuiexample/AboutActivity.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66

77
import com.google.android.material.button.MaterialButton;
88

9-
import de.dlyt.yanndroid.oneui.utils.ThemeColor;
109
import de.dlyt.yanndroid.oneui.layout.AboutPage;
10+
import de.dlyt.yanndroid.oneui.utils.ThemeColor;
1111

1212
public class AboutActivity extends AppCompatActivity {
1313

app/src/main/java/de/dlyt/yanndroid/oneuiexample/SwitchBarActivity.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,10 @@
66

77
import androidx.appcompat.app.AppCompatActivity;
88

9+
import de.dlyt.yanndroid.oneui.layout.SwitchBarLayout;
10+
import de.dlyt.yanndroid.oneui.utils.ThemeColor;
911
import de.dlyt.yanndroid.oneui.view.Switch;
1012
import de.dlyt.yanndroid.oneui.view.SwitchBar;
11-
import de.dlyt.yanndroid.oneui.utils.ThemeColor;
12-
import de.dlyt.yanndroid.oneui.layout.SwitchBarLayout;
1313

1414
public class SwitchBarActivity extends AppCompatActivity implements SwitchBar.OnSwitchChangeListener {
1515
@Override

app/src/main/java/de/dlyt/yanndroid/oneuiexample/fragments/MainActivitySecondFragment.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,15 @@
77

88
import androidx.appcompat.util.SeslMisc;
99

10-
import de.dlyt.yanndroid.oneui.utils.ThemeColor;
1110
import de.dlyt.yanndroid.oneui.layout.PreferenceFragment;
12-
import de.dlyt.yanndroid.oneui.preference.SwitchPreferenceScreen;
13-
import de.dlyt.yanndroid.oneui.preference.internal.PreferencesRelatedCard;
1411
import de.dlyt.yanndroid.oneui.preference.HorizontalRadioPreference;
1512
import de.dlyt.yanndroid.oneui.preference.Preference;
1613
import de.dlyt.yanndroid.oneui.preference.PreferenceGroup;
1714
import de.dlyt.yanndroid.oneui.preference.SwitchPreference;
15+
import de.dlyt.yanndroid.oneui.preference.SwitchPreferenceScreen;
1816
import de.dlyt.yanndroid.oneui.preference.TipsCardViewPreference;
17+
import de.dlyt.yanndroid.oneui.preference.internal.PreferencesRelatedCard;
18+
import de.dlyt.yanndroid.oneui.utils.ThemeColor;
1919
import de.dlyt.yanndroid.oneuiexample.MainActivity;
2020
import de.dlyt.yanndroid.oneuiexample.R;
2121

@@ -71,7 +71,7 @@ public void onCancelClicked(View view) {
7171
}
7272

7373
@Override
74-
public void onStart(){
74+
public void onStart() {
7575
super.onStart();
7676
SharedPreferences sharedPreferences = mContext.getSharedPreferences("de.dlyt.yanndroid.oneuiexample_preferences", Context.MODE_PRIVATE);
7777
SwitchPreferenceScreen switchPreferenceScreen = (SwitchPreferenceScreen) findPreference("switch_preference_screen");

app/src/main/java/de/dlyt/yanndroid/oneuiexample/tabs/IconsTab.java

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -175,10 +175,9 @@ public class IconsTab extends Fragment {
175175
R.drawable.ic_samsung_website,
176176
R.drawable.ic_samsung_work,
177177
-1};
178-
178+
RecyclerView listView;
179179
private View mRootView;
180180
private Context mContext;
181-
RecyclerView listView;
182181

183182
public IconsTab() {
184183
}
@@ -262,7 +261,7 @@ public ImageAdapter.ViewHolder onCreateViewHolder(ViewGroup parent, int viewType
262261

263262
@Override
264263
public void onBindViewHolder(ImageAdapter.ViewHolder holder, final int position) {
265-
if (holder.isItem) {
264+
if (holder.isItem) {
266265
holder.imageView.setImageResource(imageIDs[position]);
267266
holder.textView.setText(getResources().getResourceEntryName(imageIDs[position]));
268267
holder.parentView.setOnClickListener(new View.OnClickListener() {
@@ -286,7 +285,7 @@ public class ViewHolder extends RecyclerView.ViewHolder {
286285

287286
isItem = viewType == 0;
288287

289-
if (isItem) {
288+
if (isItem) {
290289
parentView = (RelativeLayout) itemView;
291290
imageView = parentView.findViewById(R.id.icon_tab_item_image);
292291
textView = parentView.findViewById(R.id.icon_tab_item_text);

app/src/main/java/de/dlyt/yanndroid/oneuiexample/tabs/ViewPagerAdapter.java

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -36,11 +36,15 @@ public int getCount() {
3636

3737
@Override
3838
public CharSequence getPageTitle(int position) {
39-
switch (position){
40-
case 0: return "Views";
41-
case 1: return "Icons";
42-
case 2: return "Nothing";
43-
default: return "";
39+
switch (position) {
40+
case 0:
41+
return "Views";
42+
case 1:
43+
return "Icons";
44+
case 2:
45+
return "Nothing";
46+
default:
47+
return "";
4448
}
4549
}
4650
}

app/src/main/res/layout-land/activity_switchbar.xml

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
<?xml version="1.0" encoding="utf-8"?>
2-
<de.dlyt.yanndroid.oneui.layout.SwitchBarLayout
3-
xmlns:android="http://schemas.android.com/apk/res/android"
2+
<de.dlyt.yanndroid.oneui.layout.SwitchBarLayout xmlns:android="http://schemas.android.com/apk/res/android"
43
xmlns:app="http://schemas.android.com/apk/res-auto"
54
android:id="@+id/switchbarlayout_switchbaractivity"
65
android:layout_width="match_parent"
@@ -18,19 +17,20 @@
1817
<LinearLayout
1918
android:layout_width="match_parent"
2019
android:layout_height="match_parent"
21-
android:orientation="horizontal"
22-
android:descendantFocusability="afterDescendants">
20+
android:descendantFocusability="afterDescendants"
21+
android:orientation="horizontal">
2322

2423
<de.dlyt.yanndroid.oneui.layout.RoundFrameLayout
2524
android:layout_width="0dp"
2625
android:layout_height="wrap_content"
2726
android:layout_weight="4.0"
2827
android:background="@color/switchbar_help_image_bg_color">
28+
2929
<ImageView
3030
android:layout_width="150dp"
3131
android:layout_height="150dp"
32-
android:layout_margin="20.0dip"
3332
android:layout_gravity="center"
33+
android:layout_margin="20.0dip"
3434
android:adjustViewBounds="true"
3535
android:scaleType="fitXY"
3636
android:src="@mipmap/ic_launcher" />
@@ -39,16 +39,16 @@
3939
<TextView
4040
android:layout_width="0dp"
4141
android:layout_height="wrap_content"
42-
android:layout_weight="6.0"
4342
android:layout_marginStart="@dimen/sesl_list_item_padding_horizontal"
44-
android:layout_marginEnd="@dimen/sesl_list_item_padding_horizontal"
4543
android:layout_marginTop="@dimen/sesl_list_divider_inset"
44+
android:layout_marginEnd="@dimen/sesl_list_item_padding_horizontal"
4645
android:layout_marginBottom="@dimen/sesl_list_divider_inset"
46+
android:layout_weight="6.0"
47+
android:lineSpacingExtra="4.0sp"
48+
android:text="Create custom preferences with inner PreferenceScreen."
4749
android:textAppearance="?android:textAppearanceListItem"
48-
android:textSize="15.0sp"
4950
android:textColor="@color/sesl_dialog_body_text_color"
50-
android:lineSpacingExtra="4.0sp"
51-
android:text="Create custom preferences with inner PreferenceScreen."/>
51+
android:textSize="15.0sp" />
5252

5353
</LinearLayout>
5454

app/src/main/res/layout/activity_switchbar.xml

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
<?xml version="1.0" encoding="utf-8"?>
2-
<de.dlyt.yanndroid.oneui.layout.SwitchBarLayout
3-
xmlns:android="http://schemas.android.com/apk/res/android"
2+
<de.dlyt.yanndroid.oneui.layout.SwitchBarLayout xmlns:android="http://schemas.android.com/apk/res/android"
43
xmlns:app="http://schemas.android.com/apk/res-auto"
54
android:id="@+id/switchbarlayout_switchbaractivity"
65
android:layout_width="match_parent"
@@ -10,29 +9,30 @@
109
<de.dlyt.yanndroid.oneui.view.RoundNestedScrollView
1110
android:layout_width="match_parent"
1211
android:layout_height="match_parent"
13-
android:orientation="vertical"
1412
android:background="@color/background_color"
15-
android:scrollbars="vertical"
16-
android:scrollbarStyle="outsideOverlay"
1713
android:fillViewport="true"
14+
android:orientation="vertical"
15+
android:scrollbarStyle="outsideOverlay"
16+
android:scrollbars="vertical"
1817
app:layout_behavior="@string/sesl_appbar_scrolling_view_behavior"
1918
app:roundedCorners="top_left|top_right">
2019

2120
<LinearLayout
2221
android:layout_width="match_parent"
2322
android:layout_height="match_parent"
24-
android:orientation="vertical"
25-
android:descendantFocusability="afterDescendants">
23+
android:descendantFocusability="afterDescendants"
24+
android:orientation="vertical">
2625

2726
<de.dlyt.yanndroid.oneui.layout.RoundFrameLayout
2827
android:layout_width="match_parent"
2928
android:layout_height="wrap_content"
3029
android:background="@color/switchbar_help_image_bg_color">
30+
3131
<ImageView
3232
android:layout_width="150dp"
3333
android:layout_height="150dp"
34-
android:layout_margin="20.0dip"
3534
android:layout_gravity="center"
35+
android:layout_margin="20.0dip"
3636
android:adjustViewBounds="true"
3737
android:scaleType="fitXY"
3838
android:src="@mipmap/ic_launcher" />
@@ -42,14 +42,14 @@
4242
android:layout_width="match_parent"
4343
android:layout_height="wrap_content"
4444
android:layout_marginStart="@dimen/sesl_list_item_padding_horizontal"
45-
android:layout_marginEnd="@dimen/sesl_list_item_padding_horizontal"
4645
android:layout_marginTop="@dimen/sesl_list_divider_inset"
46+
android:layout_marginEnd="@dimen/sesl_list_item_padding_horizontal"
4747
android:layout_marginBottom="@dimen/sesl_list_divider_inset"
48+
android:lineSpacingExtra="4.0sp"
49+
android:text="Create custom preferences with inner PreferenceScreen."
4850
android:textAppearance="?android:textAppearanceListItem"
49-
android:textSize="15.0sp"
5051
android:textColor="@color/sesl_dialog_body_text_color"
51-
android:lineSpacingExtra="4.0sp"
52-
android:text="Create custom preferences with inner PreferenceScreen."/>
52+
android:textSize="15.0sp" />
5353

5454
</LinearLayout>
5555

app/src/main/res/layout/fragment_icons_tab.xml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
<?xml version="1.0" encoding="utf-8"?>
2-
<de.dlyt.yanndroid.oneui.view.RecyclerView
3-
xmlns:android="http://schemas.android.com/apk/res/android"
2+
<de.dlyt.yanndroid.oneui.view.RecyclerView xmlns:android="http://schemas.android.com/apk/res/android"
43
android:id="@+id/images"
54
android:layout_width="match_parent"
65
android:layout_height="match_parent"

app/src/main/res/layout/fragment_nothing_tab.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44
android:layout_width="match_parent"
55
android:layout_height="match_parent"
66
android:background="@color/item_background_color"
7-
android:scrollbars="vertical"
87
android:fillViewport="true"
8+
android:scrollbars="vertical"
99
app:layout_behavior="@string/sesl_appbar_scrolling_view_behavior">
1010

1111
<LinearLayout
@@ -17,12 +17,12 @@
1717
android:orientation="vertical">
1818

1919
<com.google.android.material.textview.MaterialTextView
20+
style="?textAppearanceListItem"
2021
android:layout_width="wrap_content"
2122
android:layout_height="wrap_content"
2223
android:text="@string/nothing"
2324
android:textAlignment="viewStart"
24-
android:textSize="18sp"
25-
style="?textAppearanceListItem"/>
25+
android:textSize="18sp" />
2626

2727
</LinearLayout>
2828

0 commit comments

Comments
 (0)