Skip to content

Commit

Permalink
imageedit包所有样式补充z前缀,防止跟别的库中的imageedit有冲突问题
Browse files Browse the repository at this point in the history
  • Loading branch information
aaatttcccc committed Sep 16, 2022
1 parent cc097e4 commit 6247688
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 13 deletions.
2 changes: 1 addition & 1 deletion imageedit/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
android:name=".ImageEditActivity"
android:launchMode="singleTask"
android:screenOrientation="locked"
android:theme="@style/ImageEditTheme"
android:theme="@style/ZImageEditTheme"
android:windowSoftInputMode="stateAlwaysHidden" />

</application>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ public class ImageTextEditDialog extends Dialog implements View.OnClickListener,
private ImageColorGroup mColorGroup;

public ImageTextEditDialog(Context context, Callback callback) {
super(context, R.style.ImageTextDialog);
super(context, R.style.ZImageTextDialog);
setContentView(R.layout.image_text_dialog_zjh);
mCallback = callback;
Window window = getWindow();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,10 +52,10 @@ public ImageColorRadio(Context context, AttributeSet attrs, int defStyleAttr) {
}

private void initialize(Context context, AttributeSet attrs) {
TypedArray a = context.obtainStyledAttributes(attrs, R.styleable.IMGColorRadio);
TypedArray a = context.obtainStyledAttributes(attrs, R.styleable.ZIMGColorRadio);

mColor = a.getColor(R.styleable.IMGColorRadio_image_color, Color.WHITE);
mStrokeColor = a.getColor(R.styleable.IMGColorRadio_image_stroke_color, Color.WHITE);
mColor = a.getColor(R.styleable.ZIMGColorRadio_z_image_color, Color.WHITE);
mStrokeColor = a.getColor(R.styleable.ZIMGColorRadio_z_image_stroke_color, Color.WHITE);

a.recycle();

Expand Down
6 changes: 3 additions & 3 deletions imageedit/src/main/res/values/image_attrs.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@
<attr name="z_image_gallery_span_count" format="integer" />
<attr name="z_image_gallery_select_shade" format="color" />

<declare-styleable name="IMGColorRadio" tools:ignore="ResourceName">
<declare-styleable name="ZIMGColorRadio" tools:ignore="ResourceName">

<attr name="image_color" format="color" />
<attr name="image_stroke_color" format="color" />
<attr name="z_image_color" format="color" />
<attr name="z_image_stroke_color" format="color" />

</declare-styleable>

Expand Down
10 changes: 5 additions & 5 deletions imageedit/src/main/res/values/image_styles.xml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>

<style name="ImageEditTheme" parent="Theme.AppCompat.Light.NoActionBar"/>
<style name="ZImageEditTheme" parent="Theme.AppCompat.Light.NoActionBar"/>

<style name="ImageTextDialog" parent="android:Theme.Holo.Dialog">
<style name="ZImageTextDialog" parent="android:Theme.Holo.Dialog">

<item name="android:windowActionBar">false</item>
<item name="android:windowNoTitle">true</item>
Expand All @@ -19,18 +19,18 @@
<item name="android:backgroundDimEnabled">true</item>
<item name="android:backgroundDimAmount">0.8</item>

<item name="android:windowAnimationStyle">@style/ImageDialogAnimation</item>
<item name="android:windowAnimationStyle">@style/ZImageDialogAnimation</item>

</style>

<style name="ImageDialogAnimation" parent="android:Animation.Dialog">
<style name="ZImageDialogAnimation" parent="android:Animation.Dialog">

<item name="android:windowEnterAnimation">@anim/image_dialog_enter_zjh</item>
<item name="android:windowExitAnimation">@anim/image_dialog_exit_zjh</item>

</style>

<style name="ImageGalleryTheme" parent="Theme.AppCompat">
<style name="ZImageGalleryTheme" parent="Theme.AppCompat">
<item name="z_image_gallery_span_count">4</item>
<item name="z_image_gallery_select_shade">#90FFFFFF</item>
</style>
Expand Down

0 comments on commit 6247688

Please sign in to comment.