Some style fixes

filtering
Floens 10 years ago
parent ed0fa35b92
commit b36548c7dd
  1. 3
      Clover/app/src/main/java/org/floens/chan/Chan.java
  2. 2
      Clover/app/src/main/java/org/floens/chan/ui/toolbar/Toolbar.java
  3. 43
      Clover/app/src/main/java/org/floens/chan/ui/view/TouchBlockingFrameLayout.java
  4. 2
      Clover/app/src/main/res/layout/controller_navigation_drawer.xml
  5. 2
      Clover/app/src/main/res/layout/controller_navigation_image_viewer.xml
  6. 60
      Clover/app/src/main/res/values/attrs.xml
  7. 4
      Clover/app/src/main/res/values/dimens.xml
  8. 23
      Clover/app/src/main/res/values/styles.xml

@ -26,7 +26,6 @@ import android.view.ViewConfiguration;
import com.android.volley.RequestQueue;
import com.android.volley.toolbox.ImageLoader;
import com.android.volley.toolbox.Volley;
import com.squareup.leakcanary.LeakCanary;
import com.squareup.leakcanary.RefWatcher;
import org.floens.chan.chan.ChanUrls;
@ -127,7 +126,7 @@ public class Chan extends Application {
}
if (ChanBuild.DEVELOPER_MODE) {
refWatcher = LeakCanary.install(this);
// refWatcher = LeakCanary.install(this);
StrictMode.setThreadPolicy(new StrictMode.ThreadPolicy.Builder().detectAll().penaltyLog().build());
StrictMode.setVmPolicy(new StrictMode.VmPolicy.Builder().detectAll().penaltyLog().build());
}

@ -152,7 +152,7 @@ public class Toolbar extends LinearLayout implements View.OnClickListener, LoadV
setRoundItemBackground(arrowMenuView);
leftButtonContainer.addView(arrowMenuView, new FrameLayout.LayoutParams(dp(56), FrameLayout.LayoutParams.MATCH_PARENT, Gravity.CENTER_VERTICAL));
leftButtonContainer.addView(arrowMenuView, new FrameLayout.LayoutParams(getResources().getDimensionPixelSize(R.dimen.toolbar_height), FrameLayout.LayoutParams.MATCH_PARENT, Gravity.CENTER_VERTICAL));
navigationItemContainer = new LoadView(getContext());
navigationItemContainer.setListener(this);

@ -0,0 +1,43 @@
/*
* Clover - 4chan browser https://github.com/Floens/Clover/
* Copyright (C) 2014 Floens
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
package org.floens.chan.ui.view;
import android.content.Context;
import android.support.annotation.NonNull;
import android.util.AttributeSet;
import android.view.MotionEvent;
import android.widget.FrameLayout;
public class TouchBlockingFrameLayout extends FrameLayout {
public TouchBlockingFrameLayout(Context context) {
super(context);
}
public TouchBlockingFrameLayout(Context context, AttributeSet attrs) {
super(context, attrs);
}
public TouchBlockingFrameLayout(Context context, AttributeSet attrs, int defStyleAttr) {
super(context, attrs, defStyleAttr);
}
@Override
public boolean onTouchEvent(@NonNull MotionEvent event) {
return true;
}
}

@ -31,7 +31,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
<org.floens.chan.ui.toolbar.Toolbar
android:id="@+id/toolbar"
android:layout_width="match_parent"
android:layout_height="56dp"
android:layout_height="@dimen/toolbar_height"
android:background="@color/primary"
android:elevation="4dp"
tools:ignore="UnusedAttribute" />

@ -25,7 +25,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
<org.floens.chan.ui.toolbar.Toolbar
android:id="@+id/toolbar"
android:layout_width="match_parent"
android:layout_height="56dp"
android:layout_height="@dimen/toolbar_height"
android:background="#e9000000"
android:elevation="4dp"
tools:ignore="UnusedAttribute" />

@ -16,66 +16,6 @@ You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
-->
<resources>
<attr name="toolbar_theme" format="reference" />
<attr name="toolbar_popup_theme" format="reference" />
<attr name="board_pane_style" format="reference" />
<attr name="board_pane_left_style" format="reference" />
<attr name="board_pane_right_style" format="reference" />
<declare-styleable name="BoardPane">
<attr name="fade_color" format="color" />
</declare-styleable>
<attr name="post_style" format="reference" />
<declare-styleable name="PostView">
<attr name="thumbnail_background" format="color" />
<attr name="saved_reply_color" format="color" />
<attr name="highlighted_color" format="color" />
<attr name="reply_count_color" format="color" />
<attr name="name_color" format="color" />
<attr name="subject_color" format="color" />
<attr name="date_color" format="color" />
<attr name="quote_color" format="color" />
<attr name="highlight_quote_color" format="color" />
<attr name="link_color" format="color" />
<attr name="spoiler_color" format="color" />
<attr name="capcode_color" format="color" />
<attr name="id_background_light" format="color" />
<attr name="id_background_dark" format="color" />
<attr name="inline_quote_color" format="color" />
<attr name="title_size" format="dimension" />
<attr name="detail_size" format="dimension" />
<attr name="icon_padding" format="dimension" />
<attr name="icon_width" format="dimension" />
<attr name="icon_height" format="dimension" />
<attr name="options_spacing" format="dimension" />
<attr name="options_left_padding" format="dimension" />
<attr name="options_top_padding" format="dimension" />
<attr name="options_right_padding" format="dimension" />
<attr name="options_bottom_padding" format="dimension" />
<attr name="last_seen_height" format="dimension" />
<attr name="grid_padding" format="dimension" />
<attr name="grid_image_size" format="dimension" />
<attr name="grid_comment_padding" format="dimension" />
<attr name="grid_replies_count_size" format="dimension" />
<attr name="list_comment_max_height" format="dimension" />
<attr name="list_padding" format="dimension" />
<attr name="list_image_size" format="reference|dimension" />
<attr name="list_comment_padding" format="dimension" />
<attr name="list_replies_count_size" format="dimension" />
<attr name="grid_width" format="dimension" />
<attr name="grid_height" format="dimension" />
<attr name="grid_spacing" format="dimension" />
<attr name="code_tag_size" format="dimension" />
</declare-styleable>
<attr name="board_edit_item_style" format="reference" />
<attr name="text_color_primary" format="color" />
<attr name="text_color_secondary" format="color" />
<attr name="text_color_hint" format="color" />

@ -0,0 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<dimen name="toolbar_height">56dp</dimen>
</resources>

@ -18,12 +18,13 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
<resources>
<color name="primary">#ff4caf50</color>
<color name="primary_dark">#ff388e3c</color>
<color name="accent">#ff009688</color>
<!-- Main light theme -->
<style name="Chan.Theme" parent="Theme.AppCompat.Light.NoActionBar">
<item name="colorPrimary">@color/primary</item>
<item name="colorPrimaryDark">@color/primary_dark</item>
<item name="colorAccent">@color/accent_material_light</item>
<item name="colorAccent">@color/accent</item>
<item name="android:windowBackground">@android:color/white</item>
<item name="windowActionModeOverlay">true</item>
@ -63,22 +64,20 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
<style name="Chan.Theme.Dark">
<item name="backcolor">#ff232323</item>
<item name="thumbnail_background">#00000000</item>
<item name="saved_reply_color">#ff5C5C5C</item>
<item name="highlighted_color">#ff444444</item>
<item name="reply_count_color">#ff9f9f9f</item>
<item name="subject_color">#ff625cff</item>
<item name="date_color">#ff9f9f9f</item>
<item name="link_color">#ff625cff</item>
<item name="spoiler_color">#ff000000</item>
<item name="id_background_light">#00000000</item>
<item name="id_background_dark">#ffC6C6C6</item>
<item name="post_saved_reply_color">#ff5C5C5C</item>
<item name="post_highlighted_color">#ff444444</item>
<item name="post_reply_count_color">#ff9f9f9f</item>
<item name="post_subject_color">#ff625cff</item>
<item name="post_link_color">#ff625cff</item>
<item name="post_spoiler_color">#ff000000</item>
<item name="post_id_background_light">#00000000</item>
<item name="post_id_background_dark">#ffC6C6C6</item>
</style>
<style name="Chan.Theme.Black" parent="Chan.Theme.Dark">
<item name="backcolor">#ff000000</item>
<item name="spoiler_color">#ff2c2c2c</item>
<item name="post_spoiler_color">#ff2c2c2c</item>
</style>
<!-- For FloatingMenu -->

Loading…
Cancel
Save