界面UI完善,功能整合
This commit is contained in:
parent
4fa62255fa
commit
5ac7eb909d
@ -2,6 +2,11 @@
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<uses-permission android:name="android.permission.FOREGROUND_SERVICE" />
|
||||
<uses-permission android:name="android.permission.FOREGROUND_SERVICE_SPECIAL_USE" />
|
||||
<uses-permission android:name="android.permission.SYSTEM_ALERT_WINDOW" />
|
||||
<uses-permission android:name="android.permission.REQUEST_IGNORE_BATTERY_OPTIMIZATIONS" />
|
||||
|
||||
<application
|
||||
android:name=".MyApplication"
|
||||
android:allowBackup="true"
|
||||
@ -9,33 +14,48 @@
|
||||
android:fullBackupContent="@xml/backup_rules"
|
||||
android:icon="@mipmap/ic_launcher"
|
||||
android:label="@string/app_name"
|
||||
android:roundIcon="@mipmap/ic_launcher_round"
|
||||
android:roundIcon="@mipmap/ic_launcher"
|
||||
android:supportsRtl="true"
|
||||
android:theme="@style/Theme.AutoClicker"
|
||||
tools:targetApi="31">
|
||||
<activity
|
||||
android:name=".presentation.ui.activity.AccessibilityActivity"
|
||||
android:name=".ui.activity.main.QuestionActivity"
|
||||
android:exported="false" />
|
||||
<activity
|
||||
android:name=".presentation.ui.activity.menu.ScriptsActivity"
|
||||
android:name=".ui.activity.menu.FeedbackActivity"
|
||||
android:exported="false" />
|
||||
<activity
|
||||
android:name=".presentation.ui.activity.setting.SettingActivity"
|
||||
android:name=".ui.activity.menu.HowToUseActivity"
|
||||
android:exported="false" />
|
||||
<activity
|
||||
android:name=".presentation.ui.activity.menu.MenuActivity"
|
||||
android:name=".ui.activity.menu.BatteryLimitFreeActivity"
|
||||
android:exported="false" />
|
||||
<activity
|
||||
android:name=".presentation.ui.activity.MainActivity"
|
||||
android:name=".ui.activity.menu.TroubleshootingActivity"
|
||||
android:exported="false" />
|
||||
<activity
|
||||
android:name=".presentation.ui.activity.welcome.AgreementActivity"
|
||||
android:name=".ui.activity.main.AccessibilityActivity"
|
||||
android:exported="false" />
|
||||
<activity
|
||||
android:name=".presentation.ui.activity.welcome.SplashActivity"
|
||||
android:name=".ui.activity.menu.ScriptsActivity"
|
||||
android:exported="false" />
|
||||
<activity
|
||||
android:name=".presentation.ui.activity.welcome.LauncherActivity"
|
||||
android:name=".ui.activity.setting.SettingActivity"
|
||||
android:exported="false" />
|
||||
<activity
|
||||
android:name=".ui.activity.menu.MenuActivity"
|
||||
android:exported="false" />
|
||||
<activity
|
||||
android:name=".ui.activity.main.MainActivity"
|
||||
android:exported="false" />
|
||||
<activity
|
||||
android:name=".ui.activity.welcome.AgreementActivity"
|
||||
android:exported="false" />
|
||||
<activity
|
||||
android:name=".ui.activity.welcome.SplashActivity"
|
||||
android:exported="false" />
|
||||
<activity
|
||||
android:name=".ui.activity.welcome.LauncherActivity"
|
||||
android:exported="true">
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN" />
|
||||
@ -43,6 +63,25 @@
|
||||
<category android:name="android.intent.category.LAUNCHER" />
|
||||
</intent-filter>
|
||||
</activity>
|
||||
|
||||
<service
|
||||
android:name=".service.AutoClickService"
|
||||
android:enabled="true"
|
||||
android:exported="false"
|
||||
android:permission="android.permission.BIND_ACCESSIBILITY_SERVICE">
|
||||
<intent-filter>
|
||||
<action android:name="android.accessibilityservice.AccessibilityService" />
|
||||
</intent-filter>
|
||||
<meta-data
|
||||
android:name="android.accessibilityservice"
|
||||
android:resource="@xml/accessibility_service_config" />
|
||||
</service>
|
||||
|
||||
<service
|
||||
android:name=".service.ForegroundService"
|
||||
android:enabled="true"
|
||||
android:exported="false"
|
||||
android:foregroundServiceType="specialUse" />
|
||||
</application>
|
||||
|
||||
</manifest>
|
||||
@ -0,0 +1,13 @@
|
||||
package com.auto.clicker.autoclicker.data;
|
||||
|
||||
public abstract class Event {
|
||||
protected int id;
|
||||
|
||||
public Event(int id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public int getId() {
|
||||
return id;
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,40 @@
|
||||
package com.auto.clicker.autoclicker.data;
|
||||
|
||||
public class EventWrapper {
|
||||
public enum EventType { POINT, SLIDE }
|
||||
|
||||
private EventType type;
|
||||
private Event event;
|
||||
private int order; // 添加顺序编号(用于UI编号)
|
||||
|
||||
public EventWrapper(EventType type, Event event, int order) {
|
||||
this.type = type;
|
||||
this.event = event;
|
||||
this.order = order;
|
||||
}
|
||||
|
||||
|
||||
public EventType getType() {
|
||||
return type;
|
||||
}
|
||||
|
||||
public void setType(EventType type) {
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
public Event getEvent() {
|
||||
return event;
|
||||
}
|
||||
|
||||
public void setEvent(Event event) {
|
||||
this.event = event;
|
||||
}
|
||||
|
||||
public int getOrder() {
|
||||
return order;
|
||||
}
|
||||
|
||||
public void setOrder(int order) {
|
||||
this.order = order;
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,52 @@
|
||||
package com.auto.clicker.autoclicker.data;
|
||||
|
||||
import android.view.View;
|
||||
import android.view.WindowManager;
|
||||
import android.widget.TextView;
|
||||
|
||||
public class PointEvent extends Event {
|
||||
private int x;
|
||||
private int y;
|
||||
private TextView view; // 悬浮窗上的控件
|
||||
private WindowManager.LayoutParams layoutParams;
|
||||
|
||||
public PointEvent(int id, int x, int y, TextView view, WindowManager.LayoutParams layoutParams) {
|
||||
super(id);
|
||||
this.x = x;
|
||||
this.y = y;
|
||||
this.view = view;
|
||||
this.layoutParams = layoutParams;
|
||||
}
|
||||
|
||||
public int getX() {
|
||||
return x;
|
||||
}
|
||||
|
||||
public void setX(int x) {
|
||||
this.x = x;
|
||||
}
|
||||
|
||||
public int getY() {
|
||||
return y;
|
||||
}
|
||||
|
||||
public void setY(int y) {
|
||||
this.y = y;
|
||||
}
|
||||
|
||||
public View getView() {
|
||||
return view;
|
||||
}
|
||||
|
||||
public void setView(TextView view) {
|
||||
this.view = view;
|
||||
}
|
||||
|
||||
public WindowManager.LayoutParams getLayoutParams() {
|
||||
return layoutParams;
|
||||
}
|
||||
|
||||
public void setLayoutParams(WindowManager.LayoutParams layoutParams) {
|
||||
this.layoutParams = layoutParams;
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,5 @@
|
||||
package com.auto.clicker.autoclicker.data;
|
||||
|
||||
public interface PositionUpdater {
|
||||
void update(float paramX, float paramY, float dx, float dy);
|
||||
}
|
||||
@ -0,0 +1,63 @@
|
||||
package com.auto.clicker.autoclicker.data;
|
||||
|
||||
import android.view.WindowManager;
|
||||
|
||||
import com.auto.clicker.autoclicker.view.ConnectingLineView;
|
||||
|
||||
|
||||
public class SlideEvent extends Event {
|
||||
private PointEvent startPoint;
|
||||
private PointEvent endPoint;
|
||||
private ConnectingLineView lineView;
|
||||
private WindowManager.LayoutParams lineParams;
|
||||
private long durationMillis; // 滑动时间
|
||||
|
||||
public SlideEvent(int id, PointEvent startPoint, PointEvent endPoint,
|
||||
ConnectingLineView lineView, WindowManager.LayoutParams lineParams) {
|
||||
super(id);
|
||||
this.startPoint = startPoint;
|
||||
this.endPoint = endPoint;
|
||||
this.lineView = lineView;
|
||||
this.lineParams = lineParams;
|
||||
}
|
||||
|
||||
public PointEvent getStartPoint() {
|
||||
return startPoint;
|
||||
}
|
||||
|
||||
public void setStartPoint(PointEvent startPoint) {
|
||||
this.startPoint = startPoint;
|
||||
}
|
||||
|
||||
public PointEvent getEndPoint() {
|
||||
return endPoint;
|
||||
}
|
||||
|
||||
public void setEndPoint(PointEvent endPoint) {
|
||||
this.endPoint = endPoint;
|
||||
}
|
||||
|
||||
public ConnectingLineView getLineView() {
|
||||
return lineView;
|
||||
}
|
||||
|
||||
public void setLineView(ConnectingLineView lineView) {
|
||||
this.lineView = lineView;
|
||||
}
|
||||
|
||||
public WindowManager.LayoutParams getLineParams() {
|
||||
return lineParams;
|
||||
}
|
||||
|
||||
public void setLineParams(WindowManager.LayoutParams lineParams) {
|
||||
this.lineParams = lineParams;
|
||||
}
|
||||
|
||||
public long getDurationMillis() {
|
||||
return durationMillis;
|
||||
}
|
||||
|
||||
public void setDurationMillis(long durationMillis) {
|
||||
this.durationMillis = durationMillis;
|
||||
}
|
||||
}
|
||||
@ -1,55 +0,0 @@
|
||||
package com.auto.clicker.autoclicker.presentation.ui.activity;
|
||||
|
||||
import android.content.Intent;
|
||||
import android.os.Bundle;
|
||||
|
||||
import androidx.activity.EdgeToEdge;
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
import androidx.core.graphics.Insets;
|
||||
import androidx.core.view.ViewCompat;
|
||||
import androidx.core.view.WindowInsetsCompat;
|
||||
|
||||
import com.auto.clicker.autoclicker.R;
|
||||
import com.auto.clicker.autoclicker.databinding.ActivityMainBinding;
|
||||
import com.auto.clicker.autoclicker.presentation.ui.activity.menu.MenuActivity;
|
||||
import com.auto.clicker.autoclicker.presentation.ui.activity.welcome.AgreementActivity;
|
||||
import com.auto.clicker.autoclicker.presentation.ui.activity.welcome.SplashActivity;
|
||||
|
||||
public class MainActivity extends AppCompatActivity {
|
||||
private ActivityMainBinding binding;
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
|
||||
binding = ActivityMainBinding.inflate(getLayoutInflater());
|
||||
setContentView(binding.getRoot());
|
||||
|
||||
EdgeToEdge.enable(this);
|
||||
ViewCompat.setOnApplyWindowInsetsListener(findViewById(R.id.main), (v, insets) -> {
|
||||
Insets systemBars = insets.getInsets(WindowInsetsCompat.Type.systemBars());
|
||||
v.setPadding(systemBars.left, systemBars.top, systemBars.right, systemBars.bottom);
|
||||
return insets;
|
||||
});
|
||||
|
||||
initData();
|
||||
initEvent();
|
||||
}
|
||||
|
||||
private void initData() {
|
||||
|
||||
}
|
||||
|
||||
private void initEvent() {
|
||||
binding.menu.setOnClickListener(v -> {
|
||||
Intent intent = new Intent(this, MenuActivity.class);
|
||||
startActivity(intent);
|
||||
});
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onDestroy() {
|
||||
super.onDestroy();
|
||||
binding = null;
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,30 @@
|
||||
package com.auto.clicker.autoclicker.room;
|
||||
|
||||
import android.content.Context;
|
||||
|
||||
import androidx.room.Database;
|
||||
import androidx.room.Room;
|
||||
import androidx.room.RoomDatabase;
|
||||
|
||||
import com.auto.clicker.autoclicker.MyApplication;
|
||||
|
||||
@Database(entities = {TouchEventEntity.class}, version = MyApplication.DB_VERSION, exportSchema = false)
|
||||
public abstract class AppDatabase extends RoomDatabase {
|
||||
|
||||
public abstract TouchEventDao touchEventDao();
|
||||
|
||||
private static volatile AppDatabase INSTANCE;
|
||||
|
||||
public static AppDatabase getInstance(Context context) {
|
||||
if (INSTANCE == null) {
|
||||
synchronized (AppDatabase.class) {
|
||||
if (INSTANCE == null) {
|
||||
INSTANCE = Room.databaseBuilder(context.getApplicationContext(),
|
||||
AppDatabase.class, MyApplication.DB_NAME)
|
||||
.build();
|
||||
}
|
||||
}
|
||||
}
|
||||
return INSTANCE;
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,19 @@
|
||||
package com.auto.clicker.autoclicker.room;
|
||||
|
||||
import androidx.room.Dao;
|
||||
import androidx.room.Delete;
|
||||
import androidx.room.Insert;
|
||||
import androidx.room.Update;
|
||||
|
||||
@Dao
|
||||
public interface TouchEventDao {
|
||||
|
||||
@Insert
|
||||
long insertEvent(TouchEventEntity event);
|
||||
|
||||
@Delete
|
||||
void deleteEvent(TouchEventEntity event);
|
||||
|
||||
@Update
|
||||
void updateEvent(TouchEventEntity event);
|
||||
}
|
||||
@ -0,0 +1,116 @@
|
||||
package com.auto.clicker.autoclicker.room;
|
||||
|
||||
import androidx.room.Entity;
|
||||
import androidx.room.PrimaryKey;
|
||||
|
||||
@Entity(tableName = "touch_event")
|
||||
public class TouchEventEntity {
|
||||
|
||||
@PrimaryKey(autoGenerate = true)
|
||||
private int id;
|
||||
private int eventType;
|
||||
private int orderIndex;
|
||||
|
||||
private int x;
|
||||
private int y;
|
||||
|
||||
private Integer endX;
|
||||
private Integer endY;
|
||||
|
||||
private int clickInterval;
|
||||
private Integer slideDuration;
|
||||
|
||||
private int displayOrderNumber;
|
||||
|
||||
public TouchEventEntity(int eventType, int orderIndex, int x, int y, Integer endX, Integer endY, int clickInterval, Integer slideDuration, int displayOrderNumber) {
|
||||
this.eventType = eventType;
|
||||
this.orderIndex = orderIndex;
|
||||
this.x = x;
|
||||
this.y = y;
|
||||
this.endX = endX;
|
||||
this.endY = endY;
|
||||
this.clickInterval = clickInterval;
|
||||
this.slideDuration = slideDuration;
|
||||
this.displayOrderNumber = displayOrderNumber;
|
||||
}
|
||||
|
||||
public int getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(int id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public int getEventType() {
|
||||
return eventType;
|
||||
}
|
||||
|
||||
public void setEventType(int eventType) {
|
||||
this.eventType = eventType;
|
||||
}
|
||||
|
||||
public int getOrderIndex() {
|
||||
return orderIndex;
|
||||
}
|
||||
|
||||
public void setOrderIndex(int orderIndex) {
|
||||
this.orderIndex = orderIndex;
|
||||
}
|
||||
|
||||
public int getX() {
|
||||
return x;
|
||||
}
|
||||
|
||||
public void setX(int x) {
|
||||
this.x = x;
|
||||
}
|
||||
|
||||
public int getY() {
|
||||
return y;
|
||||
}
|
||||
|
||||
public void setY(int y) {
|
||||
this.y = y;
|
||||
}
|
||||
|
||||
public Integer getEndX() {
|
||||
return endX;
|
||||
}
|
||||
|
||||
public void setEndX(Integer endX) {
|
||||
this.endX = endX;
|
||||
}
|
||||
|
||||
public Integer getEndY() {
|
||||
return endY;
|
||||
}
|
||||
|
||||
public void setEndY(Integer endY) {
|
||||
this.endY = endY;
|
||||
}
|
||||
|
||||
public int getClickInterval() {
|
||||
return clickInterval;
|
||||
}
|
||||
|
||||
public void setClickInterval(int clickInterval) {
|
||||
this.clickInterval = clickInterval;
|
||||
}
|
||||
|
||||
public Integer getSlideDuration() {
|
||||
return slideDuration;
|
||||
}
|
||||
|
||||
public void setSlideDuration(Integer slideDuration) {
|
||||
this.slideDuration = slideDuration;
|
||||
}
|
||||
|
||||
public int getDisplayOrderNumber() {
|
||||
return displayOrderNumber;
|
||||
}
|
||||
|
||||
public void setDisplayOrderNumber(int displayOrderNumber) {
|
||||
this.displayOrderNumber = displayOrderNumber;
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,34 @@
|
||||
package com.auto.clicker.autoclicker.room.repository;
|
||||
|
||||
import android.app.Application;
|
||||
|
||||
import com.auto.clicker.autoclicker.room.AppDatabase;
|
||||
import com.auto.clicker.autoclicker.room.TouchEventDao;
|
||||
import com.auto.clicker.autoclicker.room.TouchEventEntity;
|
||||
|
||||
import java.util.concurrent.ExecutorService;
|
||||
import java.util.concurrent.Executors;
|
||||
|
||||
public class TouchEventRepository {
|
||||
private final TouchEventDao dao;
|
||||
private final ExecutorService executorService;
|
||||
|
||||
public TouchEventRepository(Application application) {
|
||||
AppDatabase db = AppDatabase.getInstance(application);
|
||||
this.dao = db.touchEventDao();
|
||||
this.executorService = Executors.newSingleThreadExecutor();
|
||||
}
|
||||
|
||||
public void insertEvent(TouchEventEntity touchEventEntity){
|
||||
executorService.execute(() -> dao.insertEvent(touchEventEntity));
|
||||
}
|
||||
|
||||
public void deleteEvent(TouchEventEntity touchEventEntity){
|
||||
executorService.execute(() -> dao.deleteEvent(touchEventEntity));
|
||||
}
|
||||
|
||||
public void updateEvent(TouchEventEntity touchEventEntity){
|
||||
executorService.execute(() -> dao.updateEvent(touchEventEntity));
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,18 @@
|
||||
package com.auto.clicker.autoclicker.room.viewmodel;
|
||||
|
||||
import android.app.Application;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.lifecycle.AndroidViewModel;
|
||||
|
||||
import com.auto.clicker.autoclicker.room.repository.TouchEventRepository;
|
||||
|
||||
public class TouchEventViewModel extends AndroidViewModel {
|
||||
private final TouchEventRepository repository;
|
||||
|
||||
public TouchEventViewModel(@NonNull Application application) {
|
||||
super(application);
|
||||
repository = new TouchEventRepository(application);
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,264 @@
|
||||
package com.auto.clicker.autoclicker.service;
|
||||
|
||||
import android.accessibilityservice.AccessibilityService;
|
||||
import android.accessibilityservice.GestureDescription;
|
||||
import android.content.Intent;
|
||||
import android.graphics.Path;
|
||||
import android.graphics.Point;
|
||||
import android.os.Handler;
|
||||
import android.os.Looper;
|
||||
import android.util.Log;
|
||||
import android.view.accessibility.AccessibilityEvent;
|
||||
|
||||
import androidx.localbroadcastmanager.content.LocalBroadcastManager;
|
||||
|
||||
|
||||
import com.auto.clicker.autoclicker.data.Event;
|
||||
import com.auto.clicker.autoclicker.data.EventWrapper;
|
||||
import com.auto.clicker.autoclicker.data.PointEvent;
|
||||
import com.auto.clicker.autoclicker.data.SlideEvent;
|
||||
import com.auto.clicker.autoclicker.util.ScreenUtils;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Comparator;
|
||||
import java.util.List;
|
||||
|
||||
public class AutoClickService extends AccessibilityService {
|
||||
private static final String TAG = "AutoClickService";
|
||||
private static AutoClickService instance;
|
||||
|
||||
private static final long MIN_CLICK_INTERVAL = 40;
|
||||
private static final long MAX_CLICK_INTERVAL = 10000;
|
||||
private static final int MIN_CLICK_DURATION = 50;
|
||||
private static final int MAX_CLICK_DURATION = 1000;
|
||||
private static final int MIN_SLIDE_DURATION = 100;
|
||||
private static final int MAX_SLIDE_DURATION = 2000;
|
||||
|
||||
private List<EventWrapper> runtimeEvents = new ArrayList<>();
|
||||
|
||||
private final Handler handler = new Handler(Looper.getMainLooper());
|
||||
private boolean isRunning = false;
|
||||
|
||||
private long clickInterval = 1000;
|
||||
private int clickDuration = 200;
|
||||
private int slideDuration = 500;
|
||||
private int currentEventIndex = 0;
|
||||
|
||||
@Override
|
||||
public void onCreate() {
|
||||
super.onCreate();
|
||||
instance = this;
|
||||
Point screenSize = ScreenUtils.getScreenSize(this);
|
||||
int screenWidth = screenSize.x;
|
||||
int screenHeight = screenSize.y;
|
||||
logDebug("屏幕尺寸: " + screenWidth + "x" + screenHeight);
|
||||
}
|
||||
|
||||
public static AutoClickService getInstance() {
|
||||
return instance;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onServiceConnected() {
|
||||
super.onServiceConnected();
|
||||
logDebug("无障碍服务已连接");
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onInterrupt() {
|
||||
stopClicking();
|
||||
logDebug("无障碍服务中断");
|
||||
}
|
||||
|
||||
public void clearEvents() {
|
||||
runtimeEvents.clear();
|
||||
logDebug("清除所有事件");
|
||||
}
|
||||
|
||||
public void addMultipleClickEvents(List<EventWrapper> eventWrapperList) {
|
||||
clearEvents();
|
||||
|
||||
runtimeEvents = new ArrayList<>(eventWrapperList);
|
||||
logDebug("设置多点点击事件: " + eventWrapperList.size() + " 个点");
|
||||
}
|
||||
|
||||
public void setClickInterval(long interval) {
|
||||
if (interval < MIN_CLICK_INTERVAL || interval > MAX_CLICK_INTERVAL) {
|
||||
Log.w(TAG, "点击间隔超出范围: " + interval + "ms");
|
||||
return;
|
||||
}
|
||||
this.clickInterval = interval;
|
||||
logDebug("设置点击间隔: " + interval + "ms");
|
||||
}
|
||||
|
||||
public void setClickDuration(int duration) {
|
||||
if (duration < MIN_CLICK_DURATION || duration > MAX_CLICK_DURATION) {
|
||||
Log.w(TAG, "点击时长超出范围: " + duration + "ms");
|
||||
return;
|
||||
}
|
||||
this.clickDuration = duration;
|
||||
logDebug("设置点击时长: " + duration + "ms");
|
||||
}
|
||||
|
||||
public void setSlideDuration(int duration) {
|
||||
if (duration < MIN_SLIDE_DURATION || duration > MAX_SLIDE_DURATION) {
|
||||
Log.w(TAG, "滑动时长超出范围: " + duration + "ms");
|
||||
return;
|
||||
}
|
||||
this.slideDuration = duration;
|
||||
logDebug("设置滑动时长: " + duration + "ms");
|
||||
}
|
||||
|
||||
public void startClicking() {
|
||||
if (!isRunning) {
|
||||
if (runtimeEvents.isEmpty()) {
|
||||
Log.w(TAG, "无事件队列,忽略开始");
|
||||
return;
|
||||
}
|
||||
|
||||
isRunning = true;
|
||||
currentEventIndex = 0;
|
||||
logDebug("开始执行事件队列 - 共 " + runtimeEvents.size() + " 个事件");
|
||||
executeEventsByType();
|
||||
}
|
||||
}
|
||||
|
||||
public void stopClicking() {
|
||||
if (isRunning) {
|
||||
isRunning = false;
|
||||
handler.removeCallbacksAndMessages(null);
|
||||
logDebug("停止执行事件");
|
||||
}
|
||||
}
|
||||
|
||||
public boolean isClicking() {
|
||||
return isRunning;
|
||||
}
|
||||
|
||||
private void executeEventsByType() {
|
||||
if (!isRunning || runtimeEvents.isEmpty()) {
|
||||
logDebug("跳过执行:服务未运行或事件队列为空");
|
||||
return;
|
||||
}
|
||||
|
||||
runtimeEvents.sort(Comparator.comparingInt(EventWrapper::getOrder));
|
||||
|
||||
if (currentEventIndex >= runtimeEvents.size()) {
|
||||
currentEventIndex = 0;
|
||||
}
|
||||
|
||||
EventWrapper wrapper = runtimeEvents.get(currentEventIndex);
|
||||
Event event = wrapper.getEvent();
|
||||
|
||||
if (wrapper.getType() == EventWrapper.EventType.POINT && event instanceof PointEvent) {
|
||||
performSingleClick((PointEvent) event);
|
||||
} else if (wrapper.getType() == EventWrapper.EventType.SLIDE && event instanceof SlideEvent) {
|
||||
performSlide((SlideEvent) event);
|
||||
} else {
|
||||
logDebug("未知或不匹配的事件类型,跳过执行: " + wrapper.getType());
|
||||
currentEventIndex++;
|
||||
handler.postDelayed(this::executeEventsByType, clickInterval);
|
||||
}
|
||||
}
|
||||
|
||||
private void performSingleClick(PointEvent pointEvent) {
|
||||
int x = pointEvent.getX();
|
||||
int y = pointEvent.getY();
|
||||
|
||||
logDebug("执行点击: (" + x + ", " + y + ")");
|
||||
|
||||
Path path = new Path();
|
||||
path.moveTo(x, y);
|
||||
GestureDescription.StrokeDescription stroke =
|
||||
new GestureDescription.StrokeDescription(path, 0, clickDuration);
|
||||
GestureDescription gesture =
|
||||
new GestureDescription.Builder().addStroke(stroke).build();
|
||||
|
||||
dispatchGesture(gesture, new GestureResultCallback() {
|
||||
@Override
|
||||
public void onCompleted(GestureDescription gestureDescription) {
|
||||
logDebug("点击完成");
|
||||
if (isRunning) {
|
||||
int feedbackIndex = currentEventIndex;
|
||||
currentEventIndex++;
|
||||
handler.postDelayed(() -> executeEventsByType(), clickInterval);
|
||||
flashTouchFeedback(feedbackIndex);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onCancelled(GestureDescription gestureDescription) {
|
||||
Log.e(TAG, "点击被取消");
|
||||
if (isRunning) {
|
||||
currentEventIndex++;
|
||||
handler.postDelayed(() -> executeEventsByType(), clickInterval + 300);
|
||||
}
|
||||
}
|
||||
}, null);
|
||||
}
|
||||
|
||||
private void performSlide(SlideEvent slideEvent) {
|
||||
PointEvent start = slideEvent.getStartPoint();
|
||||
PointEvent end = slideEvent.getEndPoint();
|
||||
int startX = start.getX();
|
||||
int startY = start.getY();
|
||||
int endX = end.getX();
|
||||
int endY = end.getY();
|
||||
|
||||
logDebug("执行滑动: 从 (" + startX + ", " + startY + ") 到 (" + endX + ", " + endY + ")");
|
||||
|
||||
Path path = new Path();
|
||||
path.moveTo(startX, startY);
|
||||
path.lineTo(endX, endY);
|
||||
GestureDescription.StrokeDescription stroke =
|
||||
new GestureDescription.StrokeDescription(path, 0, slideDuration);
|
||||
GestureDescription gesture =
|
||||
new GestureDescription.Builder().addStroke(stroke).build();
|
||||
|
||||
dispatchGesture(gesture, new GestureResultCallback() {
|
||||
@Override
|
||||
public void onCompleted(GestureDescription gestureDescription) {
|
||||
logDebug("滑动完成");
|
||||
if (isRunning) {
|
||||
int feedbackIndex = currentEventIndex;
|
||||
currentEventIndex++;
|
||||
handler.postDelayed(() -> executeEventsByType(), clickInterval);
|
||||
flashTouchFeedback(feedbackIndex);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onCancelled(GestureDescription gestureDescription) {
|
||||
Log.e(TAG, "滑动被取消");
|
||||
if (isRunning) {
|
||||
currentEventIndex++;
|
||||
handler.postDelayed(() -> executeEventsByType(), clickInterval + 300);
|
||||
}
|
||||
}
|
||||
}, null);
|
||||
}
|
||||
|
||||
private void flashTouchFeedback(int index) {
|
||||
Intent intent = new Intent("com.auto.autoclicker.FLASH_TOUCH_POINT");
|
||||
intent.putExtra("index", index);
|
||||
LocalBroadcastManager.getInstance(this).sendBroadcast(intent);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onAccessibilityEvent(AccessibilityEvent event) {
|
||||
}
|
||||
|
||||
private void logDebug(String message) {
|
||||
Log.d(TAG, message);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onDestroy() {
|
||||
super.onDestroy();
|
||||
instance = null;
|
||||
stopClicking();
|
||||
Intent intent = new Intent("com.auto.autoclicker.SERVICE_DESTROYED");
|
||||
LocalBroadcastManager.getInstance(this).sendBroadcast(intent);
|
||||
logDebug("无障碍服务已销毁");
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,101 @@
|
||||
package com.auto.clicker.autoclicker.service;
|
||||
|
||||
import static com.auto.clicker.autoclicker.ui.activity.main.MainActivity.FLOATING_SINGLE;
|
||||
|
||||
import android.app.Notification;
|
||||
import android.app.NotificationChannel;
|
||||
import android.app.NotificationManager;
|
||||
import android.app.PendingIntent;
|
||||
import android.app.Service;
|
||||
import android.content.Intent;
|
||||
import android.os.Build;
|
||||
import android.os.IBinder;
|
||||
import android.util.Log;
|
||||
|
||||
import androidx.core.app.NotificationCompat;
|
||||
|
||||
import com.auto.clicker.autoclicker.R;
|
||||
import com.auto.clicker.autoclicker.ui.activity.main.MainActivity;
|
||||
import com.auto.clicker.autoclicker.view.FloatingViewManager;
|
||||
|
||||
public class ForegroundService extends Service {
|
||||
private static final String TAG = "ForegroundService";
|
||||
private static final String CHANNEL_ID = "AutoClickerChannel";
|
||||
private static final int NOTIFICATION_ID = 1;
|
||||
private FloatingViewManager floatingViewManager;
|
||||
private boolean isFloatingViewShown = false;
|
||||
|
||||
@Override
|
||||
public void onCreate() {
|
||||
super.onCreate();
|
||||
createNotificationChannel();
|
||||
try {
|
||||
floatingViewManager = new FloatingViewManager(this);
|
||||
} catch (Exception e) {
|
||||
Log.e(TAG, "初始化 FloatingViewManager 失败", e);
|
||||
stopSelf();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public int onStartCommand(Intent intent, int flags, int startId) {
|
||||
int type = intent != null ? intent.getIntExtra("FLOATING_TYPE", FLOATING_SINGLE) : FLOATING_SINGLE;
|
||||
|
||||
Intent notificationIntent = new Intent(this, MainActivity.class);
|
||||
PendingIntent pendingIntent = PendingIntent.getActivity(this, 0, notificationIntent, PendingIntent.FLAG_IMMUTABLE);
|
||||
Notification notification = new NotificationCompat.Builder(this, CHANNEL_ID)
|
||||
.setContentTitle("自动点击运行中")
|
||||
.setContentText("自动点击正在后台运行")
|
||||
.setSmallIcon(R.drawable.notification)
|
||||
.setContentIntent(pendingIntent)
|
||||
.setOngoing(true)
|
||||
.build();
|
||||
|
||||
startForeground(NOTIFICATION_ID, notification);
|
||||
|
||||
if (floatingViewManager != null && !isFloatingViewShown) {
|
||||
try {
|
||||
floatingViewManager.showFloatingViews(type);
|
||||
isFloatingViewShown = true;
|
||||
} catch (SecurityException e) {
|
||||
Log.e(TAG, "未授予悬浮窗权限", e);
|
||||
stopSelf();
|
||||
}
|
||||
} else if (floatingViewManager == null) {
|
||||
stopSelf();
|
||||
}
|
||||
|
||||
return START_STICKY;
|
||||
}
|
||||
|
||||
private void createNotificationChannel() {
|
||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
|
||||
NotificationChannel channel = new NotificationChannel(
|
||||
CHANNEL_ID,
|
||||
"自动点击服务",
|
||||
NotificationManager.IMPORTANCE_LOW
|
||||
);
|
||||
channel.setDescription("自动点击前台服务通知渠道");
|
||||
NotificationManager manager = getSystemService(NotificationManager.class);
|
||||
if (manager != null) {
|
||||
manager.createNotificationChannel(channel);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onDestroy() {
|
||||
super.onDestroy();
|
||||
if (floatingViewManager != null) {
|
||||
floatingViewManager.removeFloatingViews();
|
||||
isFloatingViewShown = false;
|
||||
Log.d(TAG, "悬浮窗已移除");
|
||||
}
|
||||
stopForeground(true);
|
||||
}
|
||||
|
||||
@Override
|
||||
public IBinder onBind(Intent intent) {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
@ -1,4 +1,4 @@
|
||||
package com.auto.clicker.autoclicker.presentation.ui.activity;
|
||||
package com.auto.clicker.autoclicker.ui.activity.main;
|
||||
|
||||
import android.os.Bundle;
|
||||
|
||||
@ -0,0 +1,390 @@
|
||||
package com.auto.clicker.autoclicker.ui.activity.main;
|
||||
|
||||
import android.accessibilityservice.AccessibilityServiceInfo;
|
||||
import android.app.ActivityManager;
|
||||
import android.content.BroadcastReceiver;
|
||||
import android.content.ComponentName;
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.content.IntentFilter;
|
||||
import android.net.Uri;
|
||||
import android.os.Build;
|
||||
import android.os.Bundle;
|
||||
import android.os.PowerManager;
|
||||
import android.provider.Settings;
|
||||
import android.util.Log;
|
||||
import android.view.accessibility.AccessibilityManager;
|
||||
import android.widget.Toast;
|
||||
import android.widget.VideoView;
|
||||
|
||||
import androidx.activity.EdgeToEdge;
|
||||
import androidx.activity.result.ActivityResultLauncher;
|
||||
import androidx.activity.result.contract.ActivityResultContracts;
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
import androidx.core.graphics.Insets;
|
||||
import androidx.core.view.ViewCompat;
|
||||
import androidx.core.view.WindowInsetsCompat;
|
||||
import androidx.localbroadcastmanager.content.LocalBroadcastManager;
|
||||
|
||||
import com.auto.clicker.autoclicker.R;
|
||||
import com.auto.clicker.autoclicker.databinding.ActivityMainBinding;
|
||||
import com.auto.clicker.autoclicker.service.AutoClickService;
|
||||
import com.auto.clicker.autoclicker.service.ForegroundService;
|
||||
import com.auto.clicker.autoclicker.ui.activity.menu.MenuActivity;
|
||||
import com.auto.clicker.autoclicker.ui.activity.setting.SettingActivity;
|
||||
import com.auto.clicker.autoclicker.util.PrefUtils;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public class MainActivity extends AppCompatActivity {
|
||||
private static final String TAG = "MainActivity";
|
||||
private static final String ACTION_FLOATING_STATE_CHANGED = "com.auto.clicker.autoclicker.FLOATING_WINDOW_STATE_CHANGED";
|
||||
|
||||
private ActivityMainBinding binding;
|
||||
|
||||
public static final int FLOATING_NONE = 0;
|
||||
public static final int FLOATING_SINGLE = 1;
|
||||
public static final int FLOATING_MULTI = 2;
|
||||
|
||||
private Toast debounceToast;
|
||||
|
||||
private ActivityResultLauncher<Intent> permissionLauncher;
|
||||
|
||||
private long lastClickTime = 0;
|
||||
private static final long DEBOUNCE_INTERVAL = 500;
|
||||
|
||||
private int isFloatingShown;
|
||||
private int selectedFloatingMode = FLOATING_SINGLE;
|
||||
|
||||
private final BroadcastReceiver floatingReceiver = new BroadcastReceiver() {
|
||||
@Override
|
||||
public void onReceive(Context context, Intent intent) {
|
||||
isFloatingShown = intent.getIntExtra("isShown", FLOATING_NONE);
|
||||
logDebug("接收到浮窗状态广播: isShown = " + isFloatingShown);
|
||||
|
||||
if (isFloatingShown == FLOATING_NONE) {
|
||||
} else {
|
||||
selectedFloatingMode = isFloatingShown;
|
||||
}
|
||||
updateSelectionButtons();
|
||||
}
|
||||
};
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
|
||||
binding = ActivityMainBinding.inflate(getLayoutInflater());
|
||||
setContentView(binding.getRoot());
|
||||
|
||||
EdgeToEdge.enable(this);
|
||||
ViewCompat.setOnApplyWindowInsetsListener(findViewById(R.id.main), (v, insets) -> {
|
||||
Insets systemBars = insets.getInsets(WindowInsetsCompat.Type.systemBars());
|
||||
v.setPadding(systemBars.left, systemBars.top, systemBars.right, systemBars.bottom);
|
||||
return insets;
|
||||
});
|
||||
|
||||
initData();
|
||||
initEvent();
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onResume() {
|
||||
super.onResume();
|
||||
logDebug("onResume: 检查权限和同步服务状态");
|
||||
checkPermissions();
|
||||
syncServiceState();
|
||||
}
|
||||
|
||||
private void initData() {
|
||||
isFloatingShown = PrefUtils.getFloatingShown(this);
|
||||
if (isFloatingShown != FLOATING_NONE) {
|
||||
selectedFloatingMode = isFloatingShown;
|
||||
} else {
|
||||
selectedFloatingMode = FLOATING_SINGLE;
|
||||
}
|
||||
logDebug("initData: 初始化 isFloatingShown=" + isFloatingShown + ", selectedFloatingMode=" + selectedFloatingMode);
|
||||
|
||||
updateSelectionButtons();
|
||||
|
||||
LocalBroadcastManager.getInstance(this).registerReceiver(
|
||||
floatingReceiver, new IntentFilter(ACTION_FLOATING_STATE_CHANGED));
|
||||
|
||||
permissionLauncher = registerForActivityResult(new ActivityResultContracts.StartActivityForResult(), result -> {
|
||||
logDebug("权限回调结果: " + result.getResultCode());
|
||||
binding.getRoot().postDelayed(() -> {
|
||||
checkPermissions();
|
||||
syncServiceState();
|
||||
}, 300);
|
||||
});
|
||||
|
||||
setVideo(Uri.parse("android.resource://" + getPackageName() + "/" + R.raw.bolangblue));
|
||||
}
|
||||
|
||||
private void initEvent() {
|
||||
binding.menu.setOnClickListener(v -> {
|
||||
Intent intent = new Intent(this, MenuActivity.class);
|
||||
startActivity(intent);
|
||||
});
|
||||
|
||||
binding.question.setOnClickListener(v -> {
|
||||
Intent intent = new Intent(this, QuestionActivity.class);
|
||||
startActivity(intent);
|
||||
});
|
||||
|
||||
binding.setting.setOnClickListener(v -> {
|
||||
Intent intent = new Intent(this, SettingActivity.class);
|
||||
startActivity(intent);
|
||||
});
|
||||
|
||||
binding.animatedView.setOnClickListener(v -> onToggleFloatingWindowClicked());
|
||||
|
||||
binding.single.setOnClickListener(v -> {
|
||||
selectedFloatingMode = FLOATING_SINGLE;
|
||||
updateSelectionButtons();
|
||||
|
||||
logDebug("选择单点模式. selectedFloatingMode=" + selectedFloatingMode);
|
||||
});
|
||||
|
||||
binding.multi.setOnClickListener(v -> {
|
||||
selectedFloatingMode = FLOATING_MULTI;
|
||||
updateSelectionButtons();
|
||||
|
||||
logDebug("选择多点模式. selectedFloatingMode=" + selectedFloatingMode);
|
||||
});
|
||||
}
|
||||
|
||||
private void checkPermissions() {
|
||||
boolean accessibilityGranted = isAccessibilityServiceEnabled();
|
||||
boolean overlayGranted = Settings.canDrawOverlays(this);
|
||||
boolean batteryOptimizationIgnored = isIgnoringBatteryOptimizations();
|
||||
|
||||
logDebug("检查权限: 无障碍服务=" + accessibilityGranted + ", 悬浮窗=" + overlayGranted + ", 电池优化=" + batteryOptimizationIgnored);
|
||||
|
||||
if (!accessibilityGranted) {
|
||||
logDebug("无障碍服务未启用,请求权限");
|
||||
showPermissionRequest(Settings.ACTION_ACCESSIBILITY_SETTINGS, "请启用无障碍服务以便应用正常工作", "无法打开无障碍设置");
|
||||
setStartButtonEnabled(false);
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
if (!overlayGranted) {
|
||||
logDebug("悬浮窗权限未授予,请求权限");
|
||||
Intent intent = new Intent(Settings.ACTION_MANAGE_OVERLAY_PERMISSION, Uri.parse("package:" + getPackageName()));
|
||||
showPermissionRequest(intent, "请授予悬浮窗权限,否则无法显示浮窗", "无法打开悬浮窗设置");
|
||||
setStartButtonEnabled(false);
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
if (!batteryOptimizationIgnored) {
|
||||
logDebug("电池优化未忽略,请求权限");
|
||||
Intent intent = new Intent(Settings.ACTION_REQUEST_IGNORE_BATTERY_OPTIMIZATIONS);
|
||||
intent.setData(Uri.parse("package:" + getPackageName()));
|
||||
showPermissionRequest(intent, "请禁用电池优化,以确保应用在后台稳定运行", "无法打开电池优化设置");
|
||||
setStartButtonEnabled(false);
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
logDebug("所有权限均已授予");
|
||||
setStartButtonEnabled(true);
|
||||
|
||||
}
|
||||
|
||||
private void showPermissionRequest(String action, String toastMessage, String errorMessage) {
|
||||
try {
|
||||
Intent intent = new Intent(action);
|
||||
permissionLauncher.launch(intent);
|
||||
Toast.makeText(this, toastMessage, Toast.LENGTH_LONG).show();
|
||||
logDebug("尝试启动权限设置页面: " + action);
|
||||
} catch (Exception e) {
|
||||
Toast.makeText(this, errorMessage, Toast.LENGTH_LONG).show();
|
||||
logDebug("打开设置页面失败: " + errorMessage + ", 异常: " + e.getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
private void showPermissionRequest(Intent intent, String toastMessage, String errorMessage) {
|
||||
try {
|
||||
permissionLauncher.launch(intent);
|
||||
Toast.makeText(this, toastMessage, Toast.LENGTH_LONG).show();
|
||||
logDebug("尝试启动权限设置页面 (带URI): " + intent.getAction());
|
||||
} catch (Exception e) {
|
||||
Toast.makeText(this, errorMessage, Toast.LENGTH_LONG).show();
|
||||
logDebug("打开设置页面失败 (带URI): " + errorMessage + ", 异常: " + e.getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
private boolean isAccessibilityServiceEnabled() {
|
||||
AccessibilityManager am = (AccessibilityManager) getSystemService(Context.ACCESSIBILITY_SERVICE);
|
||||
if (am == null) return false;
|
||||
|
||||
List<AccessibilityServiceInfo> enabledServices =
|
||||
am.getEnabledAccessibilityServiceList(AccessibilityServiceInfo.FEEDBACK_ALL_MASK);
|
||||
|
||||
String expectedId = new ComponentName(this, AutoClickService.class).flattenToShortString();
|
||||
|
||||
for (AccessibilityServiceInfo enabledService : enabledServices) {
|
||||
if (enabledService.getId().equals(expectedId)) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
private boolean isIgnoringBatteryOptimizations() {
|
||||
PowerManager pm = (PowerManager) getSystemService(Context.POWER_SERVICE);
|
||||
boolean ignored = pm != null && pm.isIgnoringBatteryOptimizations(getPackageName());
|
||||
logDebug("是否忽略电池优化: " + ignored);
|
||||
return ignored;
|
||||
}
|
||||
|
||||
private void syncServiceState() {
|
||||
int currentFloatingMode = getFloatingMode();
|
||||
logDebug("同步服务状态: 当前浮窗模式 = " + currentFloatingMode);
|
||||
isFloatingShown = currentFloatingMode;
|
||||
PrefUtils.setFloatingShown(this, isFloatingShown);
|
||||
|
||||
updateSelectionButtons();
|
||||
}
|
||||
|
||||
private int getFloatingMode() {
|
||||
ActivityManager manager = (ActivityManager) getSystemService(Context.ACTIVITY_SERVICE);
|
||||
if (manager == null) {
|
||||
logDebug("ActivityManager 为空");
|
||||
return FLOATING_NONE;
|
||||
}
|
||||
|
||||
List<ActivityManager.RunningServiceInfo> runningServices = manager.getRunningServices(Integer.MAX_VALUE);
|
||||
for (ActivityManager.RunningServiceInfo service : runningServices) {
|
||||
if (ForegroundService.class.getName().equals(service.service.getClassName())) {
|
||||
|
||||
int mode = PrefUtils.getFloatingShown(this);
|
||||
logDebug("前台服务正在运行,PrefUtils 获取浮窗模式: " + mode);
|
||||
return mode;
|
||||
}
|
||||
}
|
||||
logDebug("前台服务未运行");
|
||||
return FLOATING_NONE;
|
||||
}
|
||||
|
||||
|
||||
public void onToggleFloatingWindowClicked() {
|
||||
long currentTime = System.currentTimeMillis();
|
||||
if (currentTime - lastClickTime < DEBOUNCE_INTERVAL) {
|
||||
showDebounceToast();
|
||||
logDebug("点击过于频繁");
|
||||
return;
|
||||
}
|
||||
lastClickTime = currentTime;
|
||||
logDebug("点击启动/隐藏浮窗按钮. 当前 isFloatingShown=" + isFloatingShown + ", selectedFloatingMode=" + selectedFloatingMode);
|
||||
|
||||
if (!isAccessibilityServiceEnabled() || !Settings.canDrawOverlays(this) || !isIgnoringBatteryOptimizations()) {
|
||||
Toast.makeText(this, "请授予所有必要权限", Toast.LENGTH_LONG).show();
|
||||
checkPermissions();
|
||||
logDebug("权限不足,无法启动浮窗,重新检查权限");
|
||||
return;
|
||||
}
|
||||
|
||||
if (isFloatingShown != FLOATING_NONE && isFloatingShown != selectedFloatingMode) {
|
||||
Toast.makeText(this, "已显示其他悬浮窗,请先关闭", Toast.LENGTH_SHORT).show();
|
||||
logDebug("已显示其他模式的浮窗,请先关闭");
|
||||
return;
|
||||
}
|
||||
|
||||
if (isFloatingShown == selectedFloatingMode) {
|
||||
|
||||
logDebug("隐藏当前模式浮窗: " + selectedFloatingMode);
|
||||
stopService(new Intent(this, ForegroundService.class));
|
||||
|
||||
if (AutoClickService.getInstance() != null) {
|
||||
AutoClickService.getInstance().stopClicking();
|
||||
logDebug("已停止 AutoClickService 点击");
|
||||
}
|
||||
isFloatingShown = FLOATING_NONE;
|
||||
logDebug("悬浮窗已经隐藏");
|
||||
} else {
|
||||
|
||||
logDebug("启动浮窗: " + selectedFloatingMode);
|
||||
Intent serviceIntent = new Intent(this, ForegroundService.class);
|
||||
serviceIntent.putExtra("FLOATING_TYPE", selectedFloatingMode);
|
||||
|
||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
|
||||
startForegroundService(serviceIntent);
|
||||
} else {
|
||||
startService(serviceIntent);
|
||||
}
|
||||
|
||||
isFloatingShown = selectedFloatingMode;
|
||||
logDebug("悬浮窗已显示: " + selectedFloatingMode);
|
||||
}
|
||||
|
||||
PrefUtils.setFloatingShown(this, isFloatingShown);
|
||||
broadcastFloatingState(isFloatingShown);
|
||||
updateSelectionButtons();
|
||||
|
||||
if (isFloatingShown == FLOATING_NONE) {
|
||||
setVideo(Uri.parse("android.resource://" + getPackageName() + "/" + R.raw.bolangblue));
|
||||
} else {
|
||||
setVideo(Uri.parse("android.resource://" + getPackageName() + "/" + R.raw.bolangred));
|
||||
}
|
||||
}
|
||||
|
||||
private void broadcastFloatingState(int isShown) {
|
||||
Intent intent = new Intent(ACTION_FLOATING_STATE_CHANGED);
|
||||
intent.putExtra("isShown", isShown);
|
||||
LocalBroadcastManager.getInstance(this).sendBroadcast(intent);
|
||||
logDebug("发送浮窗状态广播: isShown = " + isShown);
|
||||
}
|
||||
|
||||
private void updateSelectionButtons() {
|
||||
logDebug("更新选择按钮UI: selectedFloatingMode=" + selectedFloatingMode);
|
||||
if (selectedFloatingMode == FLOATING_SINGLE) {
|
||||
binding.single.setSelected(true);
|
||||
binding.multi.setSelected(false);
|
||||
} else if (selectedFloatingMode == FLOATING_MULTI) {
|
||||
binding.single.setSelected(false);
|
||||
binding.multi.setSelected(true);
|
||||
}
|
||||
}
|
||||
|
||||
private void setStartButtonEnabled(boolean enabled) {
|
||||
logDebug("设置启动按钮启用状态: " + enabled);
|
||||
}
|
||||
|
||||
private void setVideo(Uri uri) {
|
||||
binding.animatedVideo.setVideoURI(uri);
|
||||
binding.animatedVideo.setOnPreparedListener(mp -> {
|
||||
mp.setLooping(true);
|
||||
mp.start();
|
||||
});
|
||||
binding.animatedVideo.start();
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
protected void onDestroy() {
|
||||
super.onDestroy();
|
||||
binding = null;
|
||||
LocalBroadcastManager.getInstance(this).unregisterReceiver(floatingReceiver);
|
||||
if (debounceToast != null) {
|
||||
debounceToast.cancel();
|
||||
}
|
||||
logDebug("MainActivity onDestroy");
|
||||
}
|
||||
|
||||
private void showDebounceToast() {
|
||||
if (debounceToast == null) {
|
||||
debounceToast = Toast.makeText(this, "点击太频繁", Toast.LENGTH_SHORT);
|
||||
} else {
|
||||
debounceToast.setText("点击太频繁");
|
||||
}
|
||||
debounceToast.show();
|
||||
}
|
||||
|
||||
private void logDebug(String message) {
|
||||
Log.d(TAG, message);
|
||||
}
|
||||
}
|
||||
@ -1,4 +1,4 @@
|
||||
package com.auto.clicker.autoclicker.presentation.ui.activity.setting;
|
||||
package com.auto.clicker.autoclicker.ui.activity.main;
|
||||
|
||||
import android.os.Bundle;
|
||||
|
||||
@ -10,13 +10,13 @@ import androidx.core.view.WindowInsetsCompat;
|
||||
|
||||
import com.auto.clicker.autoclicker.R;
|
||||
|
||||
public class SettingActivity extends AppCompatActivity {
|
||||
public class QuestionActivity extends AppCompatActivity {
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
EdgeToEdge.enable(this);
|
||||
setContentView(R.layout.activity_setting);
|
||||
setContentView(R.layout.activity_question);
|
||||
ViewCompat.setOnApplyWindowInsetsListener(findViewById(R.id.main), (v, insets) -> {
|
||||
Insets systemBars = insets.getInsets(WindowInsetsCompat.Type.systemBars());
|
||||
v.setPadding(systemBars.left, systemBars.top, systemBars.right, systemBars.bottom);
|
||||
@ -0,0 +1,26 @@
|
||||
package com.auto.clicker.autoclicker.ui.activity.menu;
|
||||
|
||||
import android.os.Bundle;
|
||||
|
||||
import androidx.activity.EdgeToEdge;
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
import androidx.core.graphics.Insets;
|
||||
import androidx.core.view.ViewCompat;
|
||||
import androidx.core.view.WindowInsetsCompat;
|
||||
|
||||
import com.auto.clicker.autoclicker.R;
|
||||
|
||||
public class BatteryLimitFreeActivity extends AppCompatActivity {
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
EdgeToEdge.enable(this);
|
||||
setContentView(R.layout.activity_battery_limit_free);
|
||||
ViewCompat.setOnApplyWindowInsetsListener(findViewById(R.id.main), (v, insets) -> {
|
||||
Insets systemBars = insets.getInsets(WindowInsetsCompat.Type.systemBars());
|
||||
v.setPadding(systemBars.left, systemBars.top, systemBars.right, systemBars.bottom);
|
||||
return insets;
|
||||
});
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,26 @@
|
||||
package com.auto.clicker.autoclicker.ui.activity.menu;
|
||||
|
||||
import android.os.Bundle;
|
||||
|
||||
import androidx.activity.EdgeToEdge;
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
import androidx.core.graphics.Insets;
|
||||
import androidx.core.view.ViewCompat;
|
||||
import androidx.core.view.WindowInsetsCompat;
|
||||
|
||||
import com.auto.clicker.autoclicker.R;
|
||||
|
||||
public class FeedbackActivity extends AppCompatActivity {
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
EdgeToEdge.enable(this);
|
||||
setContentView(R.layout.activity_feedback);
|
||||
ViewCompat.setOnApplyWindowInsetsListener(findViewById(R.id.main), (v, insets) -> {
|
||||
Insets systemBars = insets.getInsets(WindowInsetsCompat.Type.systemBars());
|
||||
v.setPadding(systemBars.left, systemBars.top, systemBars.right, systemBars.bottom);
|
||||
return insets;
|
||||
});
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,67 @@
|
||||
package com.auto.clicker.autoclicker.ui.activity.menu;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.view.LayoutInflater;
|
||||
|
||||
import androidx.activity.EdgeToEdge;
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
import androidx.core.graphics.Insets;
|
||||
import androidx.core.view.ViewCompat;
|
||||
import androidx.core.view.WindowInsetsCompat;
|
||||
|
||||
import com.auto.clicker.autoclicker.R;
|
||||
import com.auto.clicker.autoclicker.databinding.ActivityHowToUseBinding;
|
||||
import com.auto.clicker.autoclicker.databinding.HowTabBinding;
|
||||
import com.auto.clicker.autoclicker.ui.adapter.menu.HowAdapter;
|
||||
import com.google.android.material.tabs.TabLayoutMediator;
|
||||
|
||||
public class HowToUseActivity extends AppCompatActivity {
|
||||
private ActivityHowToUseBinding binding;
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
EdgeToEdge.enable(this);
|
||||
binding = ActivityHowToUseBinding.inflate(getLayoutInflater());
|
||||
setContentView(binding.getRoot());
|
||||
ViewCompat.setOnApplyWindowInsetsListener(findViewById(R.id.main), (v, insets) -> {
|
||||
Insets systemBars = insets.getInsets(WindowInsetsCompat.Type.systemBars());
|
||||
v.setPadding(systemBars.left, systemBars.top, systemBars.right, systemBars.bottom);
|
||||
return insets;
|
||||
});
|
||||
|
||||
initPagerAdapter();
|
||||
initTabs();
|
||||
|
||||
binding.howViewpager.setCurrentItem(0, false);
|
||||
}
|
||||
|
||||
private void initPagerAdapter() {
|
||||
HowAdapter adapter = new HowAdapter(this);
|
||||
binding.howViewpager.setAdapter(adapter);
|
||||
}
|
||||
|
||||
private void initTabs() {
|
||||
new TabLayoutMediator(binding.howTablayout, binding.howViewpager, (tab, idx) -> {
|
||||
com.auto.clicker.autoclicker.databinding.HowTabBinding tabViewBinding = HowTabBinding.inflate(LayoutInflater.from(this));
|
||||
tab.setCustomView(tabViewBinding.getRoot());
|
||||
decorateTab(tabViewBinding, idx);
|
||||
}).attach();
|
||||
}
|
||||
|
||||
private void decorateTab(HowTabBinding tabBinding, int position) {
|
||||
String text = "";
|
||||
if (position == 0) {
|
||||
text = "Single-Point";
|
||||
} else if (position == 1) {
|
||||
text = "Multi-Point";
|
||||
}
|
||||
tabBinding.textCustom.setText(text);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onDestroy() {
|
||||
super.onDestroy();
|
||||
binding = null;
|
||||
}
|
||||
}
|
||||
@ -1,5 +1,6 @@
|
||||
package com.auto.clicker.autoclicker.presentation.ui.activity.menu;
|
||||
package com.auto.clicker.autoclicker.ui.activity.menu;
|
||||
|
||||
import android.content.Intent;
|
||||
import android.os.Bundle;
|
||||
import android.view.View;
|
||||
import android.widget.ImageView;
|
||||
@ -13,7 +14,6 @@ import androidx.core.view.ViewCompat;
|
||||
import androidx.core.view.WindowInsetsCompat;
|
||||
|
||||
import com.auto.clicker.autoclicker.R;
|
||||
import com.auto.clicker.autoclicker.databinding.ActivityMainBinding;
|
||||
import com.auto.clicker.autoclicker.databinding.ActivityMenuBinding;
|
||||
|
||||
public class MenuActivity extends AppCompatActivity {
|
||||
@ -49,6 +49,26 @@ public class MenuActivity extends AppCompatActivity {
|
||||
|
||||
private void initEvent() {
|
||||
binding.btnBack.setOnClickListener(v -> finish());
|
||||
|
||||
binding.scripts.arrow.setOnClickListener(v -> {
|
||||
Intent intent = new Intent(this, ScriptsActivity.class);
|
||||
startActivity(intent);
|
||||
});
|
||||
|
||||
binding.trouble.arrow.setOnClickListener(v -> {
|
||||
Intent intent = new Intent(this, TroubleshootingActivity.class);
|
||||
startActivity(intent);
|
||||
});
|
||||
|
||||
binding.battery.arrow.setOnClickListener(v -> {
|
||||
Intent intent = new Intent(this, BatteryLimitFreeActivity.class);
|
||||
startActivity(intent);
|
||||
});
|
||||
|
||||
binding.question.arrow.setOnClickListener(v -> {
|
||||
Intent intent = new Intent(this, HowToUseActivity.class);
|
||||
startActivity(intent);
|
||||
});
|
||||
}
|
||||
|
||||
private void setupItem(int viewId, int iconRes, String title, String subtitle) {
|
||||
@ -1,4 +1,4 @@
|
||||
package com.auto.clicker.autoclicker.presentation.ui.activity.menu;
|
||||
package com.auto.clicker.autoclicker.ui.activity.menu;
|
||||
|
||||
import android.os.Bundle;
|
||||
|
||||
@ -0,0 +1,25 @@
|
||||
package com.auto.clicker.autoclicker.ui.activity.menu;
|
||||
|
||||
import android.os.Bundle;
|
||||
|
||||
import androidx.activity.EdgeToEdge;
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
import androidx.core.graphics.Insets;
|
||||
import androidx.core.view.ViewCompat;
|
||||
import androidx.core.view.WindowInsetsCompat;
|
||||
import com.auto.clicker.autoclicker.R;
|
||||
|
||||
public class TroubleshootingActivity extends AppCompatActivity {
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
EdgeToEdge.enable(this);
|
||||
setContentView(R.layout.activity_troubleshooting);
|
||||
ViewCompat.setOnApplyWindowInsetsListener(findViewById(R.id.main), (v, insets) -> {
|
||||
Insets systemBars = insets.getInsets(WindowInsetsCompat.Type.systemBars());
|
||||
v.setPadding(systemBars.left, systemBars.top, systemBars.right, systemBars.bottom);
|
||||
return insets;
|
||||
});
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,67 @@
|
||||
package com.auto.clicker.autoclicker.ui.activity.setting;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.view.LayoutInflater;
|
||||
|
||||
import androidx.activity.EdgeToEdge;
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
import androidx.core.graphics.Insets;
|
||||
import androidx.core.view.ViewCompat;
|
||||
import androidx.core.view.WindowInsetsCompat;
|
||||
|
||||
import com.auto.clicker.autoclicker.R;
|
||||
import com.auto.clicker.autoclicker.databinding.ActivitySettingBinding;
|
||||
import com.auto.clicker.autoclicker.databinding.HowTabBinding;
|
||||
import com.auto.clicker.autoclicker.ui.adapter.setting.SettingAdapter;
|
||||
import com.google.android.material.tabs.TabLayoutMediator;
|
||||
|
||||
public class SettingActivity extends AppCompatActivity {
|
||||
private ActivitySettingBinding binding;
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
EdgeToEdge.enable(this);
|
||||
binding = ActivitySettingBinding.inflate(getLayoutInflater());
|
||||
setContentView(binding.getRoot());
|
||||
ViewCompat.setOnApplyWindowInsetsListener(findViewById(R.id.main), (v, insets) -> {
|
||||
Insets systemBars = insets.getInsets(WindowInsetsCompat.Type.systemBars());
|
||||
v.setPadding(systemBars.left, systemBars.top, systemBars.right, systemBars.bottom);
|
||||
return insets;
|
||||
});
|
||||
|
||||
initPagerAdapter();
|
||||
initTabs();
|
||||
|
||||
binding.settingViewpager.setCurrentItem(0, false);
|
||||
}
|
||||
|
||||
private void initPagerAdapter() {
|
||||
SettingAdapter adapter = new SettingAdapter(this);
|
||||
binding.settingViewpager.setAdapter(adapter);
|
||||
}
|
||||
|
||||
private void initTabs() {
|
||||
new TabLayoutMediator(binding.settingTablayout, binding.settingViewpager, (tab, idx) -> {
|
||||
com.auto.clicker.autoclicker.databinding.HowTabBinding tabViewBinding = HowTabBinding.inflate(LayoutInflater.from(this));
|
||||
tab.setCustomView(tabViewBinding.getRoot());
|
||||
decorateTab(tabViewBinding, idx);
|
||||
}).attach();
|
||||
}
|
||||
|
||||
private void decorateTab(HowTabBinding tabBinding, int position) {
|
||||
String text = "";
|
||||
if (position == 0) {
|
||||
text = "Actions";
|
||||
} else if (position == 1) {
|
||||
text = "UI Size";
|
||||
}
|
||||
tabBinding.textCustom.setText(text);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onDestroy() {
|
||||
super.onDestroy();
|
||||
binding = null;
|
||||
}
|
||||
}
|
||||
@ -1,4 +1,4 @@
|
||||
package com.auto.clicker.autoclicker.presentation.ui.activity.welcome;
|
||||
package com.auto.clicker.autoclicker.ui.activity.welcome;
|
||||
|
||||
import android.content.Intent;
|
||||
import android.os.Bundle;
|
||||
@ -13,7 +13,7 @@ import androidx.core.view.WindowInsetsCompat;
|
||||
|
||||
import com.auto.clicker.autoclicker.R;
|
||||
import com.auto.clicker.autoclicker.databinding.ActivityAgreementBinding;
|
||||
import com.auto.clicker.autoclicker.presentation.ui.activity.MainActivity;
|
||||
import com.auto.clicker.autoclicker.ui.activity.main.MainActivity;
|
||||
|
||||
public class AgreementActivity extends AppCompatActivity {
|
||||
private ActivityAgreementBinding binding;
|
||||
@ -1,15 +1,9 @@
|
||||
package com.auto.clicker.autoclicker.presentation.ui.activity.welcome;
|
||||
package com.auto.clicker.autoclicker.ui.activity.welcome;
|
||||
|
||||
import android.content.Intent;
|
||||
import android.os.Bundle;
|
||||
|
||||
import androidx.activity.EdgeToEdge;
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
import androidx.core.graphics.Insets;
|
||||
import androidx.core.view.ViewCompat;
|
||||
import androidx.core.view.WindowInsetsCompat;
|
||||
|
||||
import com.auto.clicker.autoclicker.R;
|
||||
|
||||
public class LauncherActivity extends AppCompatActivity {
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
package com.auto.clicker.autoclicker.presentation.ui.activity.welcome;
|
||||
package com.auto.clicker.autoclicker.ui.activity.welcome;
|
||||
|
||||
import android.content.Intent;
|
||||
import android.os.Bundle;
|
||||
@ -12,7 +12,7 @@ import androidx.core.view.WindowInsetsCompat;
|
||||
|
||||
import com.auto.clicker.autoclicker.R;
|
||||
import com.auto.clicker.autoclicker.databinding.ActivitySplashBinding;
|
||||
import com.auto.clicker.autoclicker.presentation.ui.activity.MainActivity;
|
||||
import com.auto.clicker.autoclicker.ui.activity.main.MainActivity;
|
||||
import com.bumptech.glide.Glide;
|
||||
import com.bumptech.glide.load.resource.bitmap.RoundedCorners;
|
||||
|
||||
@ -0,0 +1,34 @@
|
||||
package com.auto.clicker.autoclicker.ui.adapter.menu;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.fragment.app.Fragment;
|
||||
import androidx.fragment.app.FragmentActivity;
|
||||
import androidx.viewpager2.adapter.FragmentStateAdapter;
|
||||
|
||||
import com.auto.clicker.autoclicker.ui.fragment.menu.HowMultiFragment;
|
||||
import com.auto.clicker.autoclicker.ui.fragment.menu.HowSingleFragment;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
public class HowAdapter extends FragmentStateAdapter {
|
||||
private final List<Fragment> fragmentList;
|
||||
|
||||
public HowAdapter(@NonNull FragmentActivity fragmentActivity) {
|
||||
super(fragmentActivity);
|
||||
fragmentList = new ArrayList<>();
|
||||
fragmentList.add(new HowSingleFragment());
|
||||
fragmentList.add(new HowMultiFragment());
|
||||
}
|
||||
|
||||
@NonNull
|
||||
@Override
|
||||
public Fragment createFragment(int position) {
|
||||
return fragmentList.get(position);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getItemCount() {
|
||||
return fragmentList.size();
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,34 @@
|
||||
package com.auto.clicker.autoclicker.ui.adapter.setting;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.fragment.app.Fragment;
|
||||
import androidx.fragment.app.FragmentActivity;
|
||||
import androidx.viewpager2.adapter.FragmentStateAdapter;
|
||||
|
||||
import com.auto.clicker.autoclicker.ui.fragment.setting.ActionFragment;
|
||||
import com.auto.clicker.autoclicker.ui.fragment.setting.UISizeFragment;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
public class SettingAdapter extends FragmentStateAdapter {
|
||||
private final List<Fragment> fragmentList;
|
||||
|
||||
public SettingAdapter(@NonNull FragmentActivity fragmentActivity) {
|
||||
super(fragmentActivity);
|
||||
fragmentList = new ArrayList<>();
|
||||
fragmentList.add(new ActionFragment());
|
||||
fragmentList.add(new UISizeFragment());
|
||||
}
|
||||
|
||||
@NonNull
|
||||
@Override
|
||||
public Fragment createFragment(int position) {
|
||||
return fragmentList.get(position);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getItemCount() {
|
||||
return fragmentList.size();
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,20 @@
|
||||
package com.auto.clicker.autoclicker.ui.fragment.menu;
|
||||
|
||||
import android.os.Bundle;
|
||||
|
||||
import androidx.fragment.app.Fragment;
|
||||
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
|
||||
import com.auto.clicker.autoclicker.R;
|
||||
|
||||
public class HowMultiFragment extends Fragment {
|
||||
|
||||
@Override
|
||||
public View onCreateView(LayoutInflater inflater, ViewGroup container,
|
||||
Bundle savedInstanceState) {
|
||||
return inflater.inflate(R.layout.fragment_how_multi, container, false);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,20 @@
|
||||
package com.auto.clicker.autoclicker.ui.fragment.menu;
|
||||
|
||||
import android.os.Bundle;
|
||||
|
||||
import androidx.fragment.app.Fragment;
|
||||
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
|
||||
import com.auto.clicker.autoclicker.R;
|
||||
|
||||
public class HowSingleFragment extends Fragment {
|
||||
|
||||
@Override
|
||||
public View onCreateView(LayoutInflater inflater, ViewGroup container,
|
||||
Bundle savedInstanceState) {
|
||||
return inflater.inflate(R.layout.fragment_how_single, container, false);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,20 @@
|
||||
package com.auto.clicker.autoclicker.ui.fragment.setting;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
|
||||
import androidx.fragment.app.Fragment;
|
||||
|
||||
import com.auto.clicker.autoclicker.R;
|
||||
|
||||
public class ActionFragment extends Fragment {
|
||||
|
||||
|
||||
@Override
|
||||
public View onCreateView(LayoutInflater inflater, ViewGroup container,
|
||||
Bundle savedInstanceState) {
|
||||
return inflater.inflate(R.layout.fragment_action, container, false);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,20 @@
|
||||
package com.auto.clicker.autoclicker.ui.fragment.setting;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
|
||||
import androidx.fragment.app.Fragment;
|
||||
|
||||
import com.auto.clicker.autoclicker.R;
|
||||
|
||||
public class UISizeFragment extends Fragment {
|
||||
|
||||
|
||||
@Override
|
||||
public View onCreateView(LayoutInflater inflater, ViewGroup container,
|
||||
Bundle savedInstanceState) {
|
||||
return inflater.inflate(R.layout.fragment_u_i_size, container, false);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,18 @@
|
||||
package com.auto.clicker.autoclicker.util;
|
||||
|
||||
import android.content.Context;
|
||||
|
||||
public class PrefUtils {
|
||||
private static final String PREF_NAME = "app_prefs";
|
||||
private static final String KEY_FLOATING_SHOWN = "floating_window_shown";
|
||||
|
||||
public static void setFloatingShown(Context context, int shown) {
|
||||
context.getSharedPreferences(PREF_NAME, Context.MODE_PRIVATE)
|
||||
.edit().putInt(KEY_FLOATING_SHOWN, shown).apply();
|
||||
}
|
||||
|
||||
public static int getFloatingShown(Context context) {
|
||||
return context.getSharedPreferences(PREF_NAME, Context.MODE_PRIVATE)
|
||||
.getInt(KEY_FLOATING_SHOWN, 0);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,14 @@
|
||||
package com.auto.clicker.autoclicker.util;
|
||||
|
||||
import android.content.Context;
|
||||
import android.graphics.Point;
|
||||
import android.util.DisplayMetrics;
|
||||
|
||||
|
||||
public class ScreenUtils {
|
||||
|
||||
public static Point getScreenSize(Context context) {
|
||||
DisplayMetrics metrics = context.getResources().getDisplayMetrics();
|
||||
return new Point(metrics.widthPixels, metrics.heightPixels);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,13 @@
|
||||
package com.auto.clicker.autoclicker.util;
|
||||
|
||||
import android.graphics.Point;
|
||||
|
||||
|
||||
public class ViewUtils {
|
||||
|
||||
public static Point constrainToScreen(float x, float y, int maxWidth, int maxHeight) {
|
||||
int constrainedX = (int) Math.max(0, Math.min(x, maxWidth));
|
||||
int constrainedY = (int) Math.max(0, Math.min(y, maxHeight));
|
||||
return new Point(constrainedX, constrainedY);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,38 @@
|
||||
package com.auto.clicker.autoclicker.view;
|
||||
|
||||
import android.content.Context;
|
||||
import android.graphics.Canvas;
|
||||
import android.graphics.Color;
|
||||
import android.graphics.Paint;
|
||||
import android.view.View;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
|
||||
public class ConnectingLineView extends View {
|
||||
private float startX, startY, endX, endY;
|
||||
private final Paint paint;
|
||||
|
||||
public ConnectingLineView(Context context) {
|
||||
super(context);
|
||||
paint = new Paint();
|
||||
paint.setColor(Color.RED);
|
||||
paint.setAlpha(180);
|
||||
paint.setStrokeWidth(5);
|
||||
paint.setAntiAlias(true);
|
||||
paint.setStyle(Paint.Style.STROKE);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onDraw(@NonNull Canvas canvas) {
|
||||
super.onDraw(canvas);
|
||||
canvas.drawLine(startX, startY, endX, endY, paint);
|
||||
}
|
||||
|
||||
public void setPoints(float startX, float startY, float endX, float endY) {
|
||||
this.startX = startX;
|
||||
this.startY = startY;
|
||||
this.endX = endX;
|
||||
this.endY = endY;
|
||||
invalidate();
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,688 @@
|
||||
package com.auto.clicker.autoclicker.view;
|
||||
|
||||
import android.annotation.SuppressLint;
|
||||
import android.app.Activity;
|
||||
import android.content.BroadcastReceiver;
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.content.IntentFilter;
|
||||
import android.graphics.Color;
|
||||
import android.graphics.PixelFormat;
|
||||
import android.graphics.Point;
|
||||
import android.os.Build;
|
||||
import android.provider.Settings;
|
||||
import android.text.InputType;
|
||||
import android.util.Log;
|
||||
import android.view.Gravity;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.MotionEvent;
|
||||
import android.view.View;
|
||||
import android.view.WindowManager;
|
||||
import android.view.inputmethod.InputMethodManager;
|
||||
import android.widget.EditText;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.LinearLayout;
|
||||
import android.widget.TextView;
|
||||
import android.widget.Toast;
|
||||
|
||||
import androidx.appcompat.app.AlertDialog;
|
||||
import androidx.localbroadcastmanager.content.LocalBroadcastManager;
|
||||
|
||||
import com.auto.clicker.autoclicker.R;
|
||||
import com.auto.clicker.autoclicker.data.Event;
|
||||
import com.auto.clicker.autoclicker.data.EventWrapper;
|
||||
import com.auto.clicker.autoclicker.data.PointEvent;
|
||||
import com.auto.clicker.autoclicker.data.PositionUpdater;
|
||||
import com.auto.clicker.autoclicker.data.SlideEvent;
|
||||
import com.auto.clicker.autoclicker.service.AutoClickService;
|
||||
import com.auto.clicker.autoclicker.service.ForegroundService;
|
||||
import com.auto.clicker.autoclicker.util.PrefUtils;
|
||||
import com.auto.clicker.autoclicker.util.ScreenUtils;
|
||||
import com.auto.clicker.autoclicker.util.ViewUtils;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
public class FloatingViewManager {
|
||||
private static final String TAG = "FloatingViewManager";
|
||||
private static final long DEBOUNCE_INTERVAL = 500;
|
||||
private static final int TOUCH_POINT_SIZE = 100;
|
||||
|
||||
private final Context context;
|
||||
private final WindowManager windowManager;
|
||||
private final int screenWidth;
|
||||
private final int screenHeight;
|
||||
|
||||
private final List<EventWrapper> runtimeEvents = new ArrayList<>();
|
||||
private int eventOrderCounter = 1;
|
||||
|
||||
private LinearLayout multipleControlBarView;
|
||||
private WindowManager.LayoutParams multipleControlBarParams;
|
||||
|
||||
private boolean isMultipleRunning = false;
|
||||
private long lastToggleTime = 0;
|
||||
|
||||
public FloatingViewManager(Context context) {
|
||||
this.context = context;
|
||||
this.windowManager = (WindowManager) context.getSystemService(Context.WINDOW_SERVICE);
|
||||
Point screenSize = ScreenUtils.getScreenSize(context);
|
||||
this.screenWidth = screenSize.x;
|
||||
this.screenHeight = screenSize.y;
|
||||
registerBroadcastReceiver();
|
||||
Log.d(TAG, "Screen size: " + screenWidth + "x" + screenHeight);
|
||||
}
|
||||
|
||||
public void showFloatingViews(int mode) throws SecurityException {
|
||||
if (!Settings.canDrawOverlays(context)) {
|
||||
throw new SecurityException("需要悬浮窗许可");
|
||||
}
|
||||
|
||||
removeFloatingViews();
|
||||
showMultipleModeViews(mode);
|
||||
|
||||
Log.d(TAG, "添加悬浮窗, 模式 = " + mode);
|
||||
}
|
||||
|
||||
public void removeFloatingViews() {
|
||||
try {
|
||||
for (EventWrapper wrapper : new ArrayList<>(runtimeEvents)) {
|
||||
if (wrapper.getType() == EventWrapper.EventType.POINT) {
|
||||
PointEvent pe = (PointEvent) wrapper.getEvent();
|
||||
safeRemoveView(pe.getView());
|
||||
}
|
||||
}
|
||||
|
||||
for (EventWrapper wrapper : new ArrayList<>(runtimeEvents)) {
|
||||
if (wrapper.getType() == EventWrapper.EventType.SLIDE) {
|
||||
SlideEvent se = (SlideEvent) wrapper.getEvent();
|
||||
safeRemoveView(se.getStartPoint().getView());
|
||||
safeRemoveView(se.getEndPoint().getView());
|
||||
safeRemoveView(se.getLineView());
|
||||
}
|
||||
}
|
||||
|
||||
runtimeEvents.clear();
|
||||
|
||||
Log.d(TAG, "remove runtimeEvents: " + runtimeEvents.size() + " eventOrderCounter :" + eventOrderCounter);
|
||||
|
||||
if (multipleControlBarView != null) {
|
||||
safeRemoveView(multipleControlBarView);
|
||||
multipleControlBarView = null;
|
||||
}
|
||||
|
||||
isMultipleRunning = false;
|
||||
Log.d(TAG, "悬浮窗已移除");
|
||||
} catch (Exception e) {
|
||||
Log.e(TAG, "移除悬浮窗失败", e);
|
||||
isMultipleRunning = false;
|
||||
}
|
||||
}
|
||||
|
||||
private void safeRemoveView(View view) {
|
||||
try {
|
||||
windowManager.removeView(view);
|
||||
} catch (Exception e) {
|
||||
Log.w(TAG, "移除视图失败: " + view, e);
|
||||
}
|
||||
}
|
||||
|
||||
private void closeFloatingViews() {
|
||||
AutoClickService service = AutoClickService.getInstance();
|
||||
if (service != null) {
|
||||
service.stopClicking();
|
||||
} else {
|
||||
Log.d(TAG, "自动点击服务没有初始化");
|
||||
Toast.makeText(context, "请同意无障碍服务权限", Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
|
||||
updateTouchPointsBackground(R.drawable.un_touch_point);
|
||||
removeFloatingViews();
|
||||
|
||||
context.stopService(new Intent(context, ForegroundService.class));
|
||||
PrefUtils.setFloatingShown(context, 0);
|
||||
|
||||
Intent intent = new Intent("com.auto.autoclicker.FLOATING_WINDOW_STATE_CHANGED");
|
||||
intent.putExtra("isShown", false);
|
||||
LocalBroadcastManager.getInstance(context).sendBroadcast(intent);
|
||||
}
|
||||
|
||||
private void showMultipleModeViews(int mode) {
|
||||
initMultipleTouchPointView();
|
||||
initMultipleControlBar();
|
||||
|
||||
if (multipleControlBarView != null) {
|
||||
windowManager.addView(multipleControlBarView, multipleControlBarParams);
|
||||
}
|
||||
}
|
||||
|
||||
private void initMultipleTouchPointView() {
|
||||
runtimeEvents.clear();
|
||||
eventOrderCounter = 1;
|
||||
|
||||
Log.d(TAG, "init runtimeEvents: " + runtimeEvents.size() + " eventOrderCounter :" + eventOrderCounter);
|
||||
}
|
||||
|
||||
@SuppressLint("ClickableViewAccessibility")
|
||||
private void initMultipleControlBar() {
|
||||
multipleControlBarView = (LinearLayout) LayoutInflater.from(context).inflate(R.layout.multiple_control_bar, null);
|
||||
multipleControlBarParams = createControlBarParams();
|
||||
|
||||
setupDraggableView(multipleControlBarView, multipleControlBarParams, this::updateMoreControlBarPosition);
|
||||
|
||||
setupControlButtons(multipleControlBarView);
|
||||
}
|
||||
|
||||
private void setupControlButtons(LinearLayout controlBar) {
|
||||
ImageView playButton = controlBar.findViewById(R.id.play_button);
|
||||
ImageView addButton = controlBar.findViewById(R.id.add_button);
|
||||
ImageView removeButton = controlBar.findViewById(R.id.remove_button);
|
||||
ImageView slideButton = controlBar.findViewById(R.id.slide_button);
|
||||
ImageView closeButton = controlBar.findViewById(R.id.close_button);
|
||||
ImageView settingButton = controlBar.findViewById(R.id.settings_button);
|
||||
|
||||
playButton.setOnClickListener(v -> toggleMultipleClicking());
|
||||
addButton.setOnClickListener(v -> addPointEvent());
|
||||
removeButton.setOnClickListener(v -> removeLastEvent());
|
||||
slideButton.setOnClickListener(v -> addSlideEvent());
|
||||
closeButton.setOnClickListener(v -> closeFloatingViews());
|
||||
settingButton.setOnClickListener(v -> showInputDialog());
|
||||
}
|
||||
|
||||
private TextView createTouchPointView(String label) {
|
||||
TextView touchPointView = new TextView(context);
|
||||
touchPointView.setBackgroundResource(R.drawable.un_touch_point);
|
||||
touchPointView.setGravity(Gravity.CENTER);
|
||||
touchPointView.setText(label);
|
||||
touchPointView.setTextColor(Color.BLACK);
|
||||
touchPointView.setTextSize(16);
|
||||
return touchPointView;
|
||||
}
|
||||
|
||||
private WindowManager.LayoutParams createTouchPointParams() {
|
||||
int overlayType = Build.VERSION.SDK_INT >= Build.VERSION_CODES.O ?
|
||||
WindowManager.LayoutParams.TYPE_APPLICATION_OVERLAY :
|
||||
WindowManager.LayoutParams.TYPE_PHONE;
|
||||
|
||||
WindowManager.LayoutParams params = new WindowManager.LayoutParams(
|
||||
TOUCH_POINT_SIZE, TOUCH_POINT_SIZE,
|
||||
overlayType,
|
||||
WindowManager.LayoutParams.FLAG_NOT_FOCUSABLE |
|
||||
WindowManager.LayoutParams.FLAG_NOT_TOUCH_MODAL,
|
||||
PixelFormat.TRANSLUCENT
|
||||
);
|
||||
params.gravity = Gravity.TOP | Gravity.START;
|
||||
return params;
|
||||
}
|
||||
|
||||
private WindowManager.LayoutParams createControlBarParams() {
|
||||
int overlayType = Build.VERSION.SDK_INT >= Build.VERSION_CODES.O ?
|
||||
WindowManager.LayoutParams.TYPE_APPLICATION_OVERLAY :
|
||||
WindowManager.LayoutParams.TYPE_PHONE;
|
||||
|
||||
WindowManager.LayoutParams params = new WindowManager.LayoutParams(
|
||||
WindowManager.LayoutParams.WRAP_CONTENT,
|
||||
WindowManager.LayoutParams.WRAP_CONTENT,
|
||||
overlayType,
|
||||
WindowManager.LayoutParams.FLAG_NOT_FOCUSABLE |
|
||||
WindowManager.LayoutParams.FLAG_NOT_TOUCH_MODAL,
|
||||
PixelFormat.TRANSLUCENT
|
||||
);
|
||||
params.gravity = Gravity.TOP | Gravity.START;
|
||||
params.x = 0;
|
||||
params.y = 200;
|
||||
return params;
|
||||
}
|
||||
|
||||
private WindowManager.LayoutParams createLineViewParams() {
|
||||
int overlayType = Build.VERSION.SDK_INT >= Build.VERSION_CODES.O ?
|
||||
WindowManager.LayoutParams.TYPE_APPLICATION_OVERLAY :
|
||||
WindowManager.LayoutParams.TYPE_PHONE;
|
||||
|
||||
WindowManager.LayoutParams params = new WindowManager.LayoutParams(
|
||||
WindowManager.LayoutParams.MATCH_PARENT,
|
||||
WindowManager.LayoutParams.MATCH_PARENT,
|
||||
overlayType,
|
||||
WindowManager.LayoutParams.FLAG_NOT_FOCUSABLE |
|
||||
WindowManager.LayoutParams.FLAG_NOT_TOUCH_MODAL |
|
||||
WindowManager.LayoutParams.FLAG_NOT_TOUCHABLE,
|
||||
PixelFormat.TRANSLUCENT
|
||||
);
|
||||
params.gravity = Gravity.TOP | Gravity.START;
|
||||
params.x = 0;
|
||||
params.y = 0;
|
||||
return params;
|
||||
}
|
||||
|
||||
@SuppressLint("ClickableViewAccessibility")
|
||||
private void addPointEvent() {
|
||||
if (isMultipleRunning) {
|
||||
Toast.makeText(context, "请停止点击", Toast.LENGTH_SHORT).show();
|
||||
return;
|
||||
}
|
||||
|
||||
TextView point = createTouchPointView(String.valueOf(eventOrderCounter));
|
||||
|
||||
WindowManager.LayoutParams params = createTouchPointParams();
|
||||
params.x = screenWidth / 2 - TOUCH_POINT_SIZE / 2;
|
||||
params.y = screenHeight / 2 - TOUCH_POINT_SIZE / 2;
|
||||
|
||||
PointEvent pointEvent = new PointEvent(eventOrderCounter, params.x, params.y, point, params);
|
||||
|
||||
runtimeEvents.add(new EventWrapper(EventWrapper.EventType.POINT, pointEvent, eventOrderCounter));
|
||||
eventOrderCounter++;
|
||||
|
||||
Log.d(TAG, "addPoint runtimeEvents: " + runtimeEvents.size() + " eventOrderCounter :" + eventOrderCounter);
|
||||
|
||||
setupDraggablePoint(point, params, pointEvent);
|
||||
windowManager.addView(point, params);
|
||||
updateServicePositions();
|
||||
}
|
||||
|
||||
@SuppressLint("ClickableViewAccessibility")
|
||||
private void addSlideEvent() {
|
||||
if (isMultipleRunning) {
|
||||
Toast.makeText(context, "请先停止点击", Toast.LENGTH_SHORT).show();
|
||||
return;
|
||||
}
|
||||
|
||||
TextView startPoint = createTouchPointView(String.valueOf(eventOrderCounter));
|
||||
WindowManager.LayoutParams startParams = createTouchPointParams();
|
||||
startParams.x = screenWidth / 2 - 100;
|
||||
startParams.y = screenHeight / 2 - 50;
|
||||
PointEvent startPointEvent = new PointEvent(eventOrderCounter, startParams.x, startParams.y, startPoint, startParams);
|
||||
|
||||
TextView endPoint = createTouchPointView(String.valueOf(eventOrderCounter));
|
||||
WindowManager.LayoutParams endParams = createTouchPointParams();
|
||||
endParams.x = screenWidth / 2 + 100;
|
||||
endParams.y = screenHeight / 2 - 50;
|
||||
PointEvent endPointEvent = new PointEvent(eventOrderCounter, endParams.x, endParams.y, endPoint, endParams);
|
||||
|
||||
ConnectingLineView lineView = new ConnectingLineView(context);
|
||||
WindowManager.LayoutParams lineParams = createLineViewParams();
|
||||
|
||||
SlideEvent slideEvent = new SlideEvent(eventOrderCounter, startPointEvent, endPointEvent, lineView, lineParams);
|
||||
|
||||
runtimeEvents.add(new EventWrapper(EventWrapper.EventType.SLIDE, slideEvent, eventOrderCounter));
|
||||
eventOrderCounter++;
|
||||
|
||||
Log.d(TAG, "addSlide runtimeEvents: " + runtimeEvents.size() + " eventOrderCounter :" + eventOrderCounter);
|
||||
|
||||
setupDraggableSlidePoint(startPoint, startParams, startPointEvent, slideEvent);
|
||||
setupDraggableSlidePoint(endPoint, endParams, endPointEvent, slideEvent);
|
||||
|
||||
windowManager.addView(lineView, lineParams);
|
||||
windowManager.addView(startPoint, startParams);
|
||||
windowManager.addView(endPoint, endParams);
|
||||
|
||||
updateLinePosition(slideEvent);
|
||||
updateServicePositions();
|
||||
}
|
||||
|
||||
private void removeLastEvent() {
|
||||
if (isMultipleRunning) {
|
||||
Toast.makeText(context, "请先停止点击", Toast.LENGTH_SHORT).show();
|
||||
return;
|
||||
}
|
||||
|
||||
if (runtimeEvents.isEmpty()) {
|
||||
Toast.makeText(context, "没有更多的事件需要删除", Toast.LENGTH_SHORT).show();
|
||||
return;
|
||||
}
|
||||
|
||||
Event lastEvent = runtimeEvents.remove(runtimeEvents.size() - 1).getEvent();
|
||||
removeEvent(lastEvent);
|
||||
eventOrderCounter--;
|
||||
updateServicePositions();
|
||||
}
|
||||
|
||||
private void removeEvent(Event event) {
|
||||
try {
|
||||
if (event instanceof PointEvent) {
|
||||
PointEvent pointEvent = (PointEvent) event;
|
||||
windowManager.removeView(pointEvent.getView());
|
||||
} else if (event instanceof SlideEvent) {
|
||||
SlideEvent slideEvent = (SlideEvent) event;
|
||||
windowManager.removeView(slideEvent.getStartPoint().getView());
|
||||
windowManager.removeView(slideEvent.getEndPoint().getView());
|
||||
windowManager.removeView(slideEvent.getLineView());
|
||||
}
|
||||
} catch (Exception e) {
|
||||
Log.w(TAG, "删除事件失败", e);
|
||||
}
|
||||
}
|
||||
|
||||
private void updateServicePositions() {
|
||||
AutoClickService service = AutoClickService.getInstance();
|
||||
if (service != null) {
|
||||
service.addMultipleClickEvents(runtimeEvents);
|
||||
}
|
||||
}
|
||||
|
||||
private void toggleMultipleClicking() {
|
||||
if (isDebounced()) return;
|
||||
|
||||
AutoClickService service = AutoClickService.getInstance();
|
||||
if (service == null) {
|
||||
handleMissingService();
|
||||
return;
|
||||
}
|
||||
|
||||
if (runtimeEvents.isEmpty()) {
|
||||
Toast.makeText(context, "请添加一个触摸点或者滑动事件", Toast.LENGTH_SHORT).show();
|
||||
return;
|
||||
}
|
||||
|
||||
if (isMultipleRunning) {
|
||||
stopMultiClicking(service);
|
||||
} else {
|
||||
startMultiClicking(service);
|
||||
}
|
||||
|
||||
isMultipleRunning = !isMultipleRunning;
|
||||
Log.d(TAG, "多点点击服务状态: " + service.isClicking());
|
||||
}
|
||||
|
||||
private void startMultiClicking(AutoClickService service) {
|
||||
service.addMultipleClickEvents(runtimeEvents);
|
||||
service.startClicking();
|
||||
|
||||
Log.d(TAG, "开始多点点击事件 " + runtimeEvents.size());
|
||||
Toast.makeText(context, "多点点击开始", Toast.LENGTH_SHORT).show();
|
||||
|
||||
updateTouchPointsBackground(R.drawable.touch_point);
|
||||
}
|
||||
|
||||
private void stopMultiClicking(AutoClickService service) {
|
||||
service.stopClicking();
|
||||
Toast.makeText(context, "多点点击停止", Toast.LENGTH_SHORT).show();
|
||||
|
||||
updateTouchPointsBackground(R.drawable.un_touch_point);
|
||||
}
|
||||
|
||||
private void updateTouchPointsBackground(int resourceId) {
|
||||
for (EventWrapper wrapper : new ArrayList<>(runtimeEvents)) {
|
||||
if (wrapper.getType() == EventWrapper.EventType.POINT) {
|
||||
PointEvent pe = (PointEvent) wrapper.getEvent();
|
||||
pe.getView().setBackgroundResource(resourceId);
|
||||
}
|
||||
}
|
||||
|
||||
for (EventWrapper wrapper : new ArrayList<>(runtimeEvents)) {
|
||||
if (wrapper.getType() == EventWrapper.EventType.SLIDE) {
|
||||
SlideEvent se = (SlideEvent) wrapper.getEvent();
|
||||
se.getStartPoint().getView().setBackgroundResource(resourceId);
|
||||
se.getEndPoint().getView().setBackgroundResource(resourceId);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void handleMissingService() {
|
||||
Log.e(TAG, "自动点击服务没有初始化");
|
||||
Toast.makeText(context, "请在设置里同意无障碍服务", Toast.LENGTH_LONG).show();
|
||||
Intent intent = new Intent(Settings.ACTION_ACCESSIBILITY_SETTINGS);
|
||||
intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
|
||||
context.startActivity(intent);
|
||||
}
|
||||
|
||||
private boolean isDebounced() {
|
||||
long currentTime = System.currentTimeMillis();
|
||||
if (currentTime - lastToggleTime < DEBOUNCE_INTERVAL) {
|
||||
return true;
|
||||
}
|
||||
lastToggleTime = currentTime;
|
||||
return false;
|
||||
}
|
||||
|
||||
@SuppressLint("ClickableViewAccessibility")
|
||||
private void setupDraggableView(View view, WindowManager.LayoutParams params, PositionUpdater positionUpdater) {
|
||||
view.setOnTouchListener(new View.OnTouchListener() {
|
||||
private float lastX, lastY;
|
||||
private float paramX, paramY;
|
||||
private boolean isDragging = false;
|
||||
|
||||
@Override
|
||||
public boolean onTouch(View v, MotionEvent event) {
|
||||
if (isMultipleRunning) {
|
||||
if (event.getAction() == MotionEvent.ACTION_UP) {
|
||||
v.performClick();
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
switch (event.getAction()) {
|
||||
case MotionEvent.ACTION_DOWN:
|
||||
lastX = event.getRawX();
|
||||
lastY = event.getRawY();
|
||||
paramX = params.x;
|
||||
paramY = params.y;
|
||||
isDragging = true;
|
||||
return true;
|
||||
|
||||
case MotionEvent.ACTION_MOVE:
|
||||
if (isDragging) {
|
||||
float dx = event.getRawX() - lastX;
|
||||
float dy = event.getRawY() - lastY;
|
||||
positionUpdater.update(paramX, paramY, dx, dy);
|
||||
return true;
|
||||
}
|
||||
break;
|
||||
|
||||
case MotionEvent.ACTION_UP:
|
||||
isDragging = false;
|
||||
v.performClick();
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@SuppressLint("ClickableViewAccessibility")
|
||||
private void setupDraggablePoint(TextView point, WindowManager.LayoutParams params, PointEvent pointEvent) {
|
||||
point.setOnTouchListener(new View.OnTouchListener() {
|
||||
private float lastX, lastY;
|
||||
private float paramX, paramY;
|
||||
|
||||
@Override
|
||||
public boolean onTouch(View v, MotionEvent event) {
|
||||
if (isMultipleRunning) {
|
||||
if (event.getAction() == MotionEvent.ACTION_UP) {
|
||||
v.performClick();
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
switch (event.getAction()) {
|
||||
case MotionEvent.ACTION_DOWN:
|
||||
lastX = event.getRawX();
|
||||
lastY = event.getRawY();
|
||||
paramX = params.x;
|
||||
paramY = params.y;
|
||||
return true;
|
||||
case MotionEvent.ACTION_MOVE:
|
||||
float dx = event.getRawX() - lastX;
|
||||
float dy = event.getRawY() - lastY;
|
||||
Point constrainedPoint = ViewUtils.constrainToScreen(
|
||||
paramX + dx, paramY + dy,
|
||||
screenWidth - point.getWidth(), screenHeight - point.getHeight());
|
||||
params.x = constrainedPoint.x;
|
||||
params.y = constrainedPoint.y;
|
||||
pointEvent.setX(params.x);
|
||||
pointEvent.setY(params.y);
|
||||
windowManager.updateViewLayout(point, params);
|
||||
updateServicePositions();
|
||||
return true;
|
||||
case MotionEvent.ACTION_UP:
|
||||
v.performClick();
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@SuppressLint("ClickableViewAccessibility")
|
||||
private void setupDraggableSlidePoint(TextView point, WindowManager.LayoutParams params,
|
||||
PointEvent pointEvent, SlideEvent slideEvent) {
|
||||
point.setOnTouchListener(new View.OnTouchListener() {
|
||||
private float lastX, lastY;
|
||||
private float paramX, paramY;
|
||||
|
||||
@Override
|
||||
public boolean onTouch(View v, MotionEvent event) {
|
||||
if (isMultipleRunning) {
|
||||
if (event.getAction() == MotionEvent.ACTION_UP) {
|
||||
v.performClick();
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
switch (event.getAction()) {
|
||||
case MotionEvent.ACTION_DOWN:
|
||||
lastX = event.getRawX();
|
||||
lastY = event.getRawY();
|
||||
paramX = params.x;
|
||||
paramY = params.y;
|
||||
return true;
|
||||
case MotionEvent.ACTION_MOVE:
|
||||
float dx = event.getRawX() - lastX;
|
||||
float dy = event.getRawY() - lastY;
|
||||
Point constrainedPoint = ViewUtils.constrainToScreen(
|
||||
paramX + dx, paramY + dy,
|
||||
screenWidth - point.getWidth(), screenHeight - point.getHeight());
|
||||
params.x = constrainedPoint.x;
|
||||
params.y = constrainedPoint.y;
|
||||
pointEvent.setX(params.x);
|
||||
pointEvent.setY(params.y);
|
||||
windowManager.updateViewLayout(point, params);
|
||||
|
||||
updateLinePosition(slideEvent);
|
||||
updateServicePositions();
|
||||
return true;
|
||||
case MotionEvent.ACTION_UP:
|
||||
v.performClick();
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private void updateMoreControlBarPosition(float paramX, float paramY, float dx, float dy) {
|
||||
Point constrainedPoint = ViewUtils.constrainToScreen(
|
||||
paramX + dx, paramY + dy,
|
||||
screenWidth - multipleControlBarView.getWidth(),
|
||||
screenHeight - multipleControlBarView.getHeight());
|
||||
multipleControlBarParams.x = constrainedPoint.x;
|
||||
multipleControlBarParams.y = constrainedPoint.y;
|
||||
windowManager.updateViewLayout(multipleControlBarView, multipleControlBarParams);
|
||||
}
|
||||
|
||||
private void updateLinePosition(SlideEvent slideEvent) {
|
||||
PointEvent start = slideEvent.getStartPoint();
|
||||
PointEvent end = slideEvent.getEndPoint();
|
||||
ConnectingLineView lineView = slideEvent.getLineView();
|
||||
|
||||
float startCenterX = start.getX() + (float) TOUCH_POINT_SIZE / 2;
|
||||
float startCenterY = start.getY() + (float) TOUCH_POINT_SIZE / 2;
|
||||
float endCenterX = end.getX() + (float) TOUCH_POINT_SIZE / 2;
|
||||
float endCenterY = end.getY() + (float) TOUCH_POINT_SIZE / 2;
|
||||
|
||||
lineView.setPoints(startCenterX, startCenterY, endCenterX, endCenterY);
|
||||
}
|
||||
|
||||
public void showInputDialog() {
|
||||
EditText input = new EditText(context);
|
||||
input.setInputType(InputType.TYPE_CLASS_NUMBER);
|
||||
input.setHint("输入点击间隔(ms)");
|
||||
input.setFocusableInTouchMode(true);
|
||||
|
||||
AlertDialog.Builder builder = new AlertDialog.Builder(context);
|
||||
builder.setTitle("设置点击间隔")
|
||||
.setView(input)
|
||||
.setPositiveButton("确定", (dialog, which) -> {
|
||||
String value = input.getText().toString();
|
||||
try {
|
||||
long interval = Long.parseLong(value);
|
||||
AutoClickService service = AutoClickService.getInstance();
|
||||
if (service != null) {
|
||||
service.setClickInterval(interval);
|
||||
} else {
|
||||
Log.w("InputDialog", "AutoClickService 未初始化");
|
||||
}
|
||||
} catch (NumberFormatException e) {
|
||||
Toast.makeText(context, "无效输入", Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
dialog.dismiss();
|
||||
})
|
||||
.setNegativeButton("取消", (dialog, which) -> dialog.dismiss());
|
||||
|
||||
AlertDialog dialog = builder.create();
|
||||
|
||||
if (!(context instanceof Activity)) {
|
||||
if (dialog.getWindow() != null) {
|
||||
dialog.getWindow().setType(
|
||||
Build.VERSION.SDK_INT >= Build.VERSION_CODES.O ?
|
||||
WindowManager.LayoutParams.TYPE_APPLICATION_OVERLAY :
|
||||
WindowManager.LayoutParams.TYPE_PHONE
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
dialog.show();
|
||||
|
||||
input.requestFocus();
|
||||
input.post(() -> {
|
||||
InputMethodManager imm = (InputMethodManager) context.getSystemService(Context.INPUT_METHOD_SERVICE);
|
||||
if (imm != null) {
|
||||
imm.toggleSoftInput(InputMethodManager.SHOW_FORCED, 0);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
public void flashTouchPoint(int index) {
|
||||
if (index >= 0 && index < runtimeEvents.size()) {
|
||||
Event event = runtimeEvents.get(index).getEvent();
|
||||
Log.d(TAG, "index : " + index);
|
||||
|
||||
if (event instanceof PointEvent) {
|
||||
flashView(((PointEvent) event).getView());
|
||||
} else if (event instanceof SlideEvent) {
|
||||
SlideEvent slide = (SlideEvent) event;
|
||||
flashView(slide.getStartPoint().getView());
|
||||
flashView(slide.getEndPoint().getView());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void flashView(View view) {
|
||||
if (view != null) {
|
||||
view.animate()
|
||||
.alpha(0.3f)
|
||||
.setDuration(100)
|
||||
.withEndAction(() -> view.animate()
|
||||
.alpha(1.0f)
|
||||
.setDuration(100)
|
||||
.start())
|
||||
.start();
|
||||
}
|
||||
}
|
||||
|
||||
private void registerBroadcastReceiver() {
|
||||
LocalBroadcastManager.getInstance(context).registerReceiver(
|
||||
new BroadcastReceiver() {
|
||||
@Override
|
||||
public void onReceive(Context context, Intent intent) {
|
||||
if ("com.auto.autoclicker.FLASH_TOUCH_POINT".equals(intent.getAction())) {
|
||||
int index = intent.getIntExtra("index", -1);
|
||||
flashTouchPoint(index);
|
||||
}
|
||||
}
|
||||
},
|
||||
new IntentFilter("com.auto.autoclicker.FLASH_TOUCH_POINT")
|
||||
);
|
||||
}
|
||||
}
|
||||
4
app/src/main/res/color/switch_thumb_selector.xml
Normal file
4
app/src/main/res/color/switch_thumb_selector.xml
Normal file
@ -0,0 +1,4 @@
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:color="#E8E8E8" android:state_checked="true"/>
|
||||
<item android:color="#A1A1A1"/>
|
||||
</selector>
|
||||
4
app/src/main/res/color/switch_track_selector.xml
Normal file
4
app/src/main/res/color/switch_track_selector.xml
Normal file
@ -0,0 +1,4 @@
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:color="#25ADCC" android:state_checked="true"/>
|
||||
<item android:color="#284650"/>
|
||||
</selector>
|
||||
5
app/src/main/res/color/tab_text_color_selector.xml
Normal file
5
app/src/main/res/color/tab_text_color_selector.xml
Normal file
@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:state_selected="true" android:color="@color/white" />
|
||||
<item android:color="@color/gray" />
|
||||
</selector>
|
||||
9
app/src/main/res/drawable/add.xml
Normal file
9
app/src/main/res/drawable/add.xml
Normal file
@ -0,0 +1,9 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="14dp"
|
||||
android:height="14dp"
|
||||
android:viewportWidth="14"
|
||||
android:viewportHeight="14">
|
||||
<path
|
||||
android:pathData="M12.657,6.004H7.589V0.936C7.589,0.564 7.289,0.256 6.909,0.256C6.529,0.256 6.229,0.556 6.229,0.936V6.004H1.169C0.797,6.004 0.489,6.304 0.489,6.684C0.489,7.064 0.789,7.364 1.169,7.364H6.237V12.432C6.237,12.804 6.537,13.112 6.917,13.112C7.296,13.112 7.597,12.812 7.597,12.432V7.364H12.665C13.037,7.364 13.345,7.064 13.345,6.684C13.345,6.304 13.045,6.004 12.665,6.004H12.657Z"
|
||||
android:fillColor="#F9F9F9"/>
|
||||
</vector>
|
||||
6
app/src/main/res/drawable/bg_rounded_rect.xml
Normal file
6
app/src/main/res/drawable/bg_rounded_rect.xml
Normal file
@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="rectangle">
|
||||
<solid android:color="@color/bg_blue"/>
|
||||
<corners android:radius="8dp" />
|
||||
</shape>
|
||||
9
app/src/main/res/drawable/blue_arrow_down.xml
Normal file
9
app/src/main/res/drawable/blue_arrow_down.xml
Normal file
@ -0,0 +1,9 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="13dp"
|
||||
android:height="6dp"
|
||||
android:viewportWidth="13"
|
||||
android:viewportHeight="6">
|
||||
<path
|
||||
android:pathData="M6.5,6L12.995,0H0.005L6.5,6Z"
|
||||
android:fillColor="#0BC4FC"/>
|
||||
</vector>
|
||||
9
app/src/main/res/drawable/blue_ring.xml
Normal file
9
app/src/main/res/drawable/blue_ring.xml
Normal file
@ -0,0 +1,9 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="47dp"
|
||||
android:height="47dp"
|
||||
android:viewportWidth="47"
|
||||
android:viewportHeight="47">
|
||||
<path
|
||||
android:pathData="M23.5,0C10.522,0 0,10.522 0,23.5C0,36.478 10.522,47 23.5,47C36.478,47 47,36.478 47,23.5C47,10.522 36.478,0 23.5,0ZM23.743,44.908C23.743,44.908 23.788,44.786 23.788,44.726V40.177C23.788,39.601 23.318,39.146 22.757,39.146C22.196,39.146 21.726,39.617 21.726,40.177V44.726C21.726,44.726 21.741,44.802 21.741,44.832C11.098,43.953 2.653,35.265 2.138,24.531H6.08C6.656,24.531 7.111,24.061 7.111,23.5C7.111,22.939 6.641,22.469 6.08,22.469H2.123C2.638,11.72 11.083,3.047 21.726,2.168C21.726,2.214 21.711,2.244 21.711,2.274V6.823C21.711,7.399 22.181,7.854 22.742,7.854C23.303,7.854 23.773,7.384 23.773,6.823V2.274C23.773,2.274 23.743,2.153 23.727,2.092C35.083,2.214 44.317,11.219 44.862,22.469H40.92C40.344,22.469 39.889,22.939 39.889,23.5C39.889,24.061 40.359,24.531 40.92,24.531H44.862C44.317,35.781 35.083,44.786 23.727,44.908H23.743Z"
|
||||
android:fillColor="#0BC4FC"/>
|
||||
</vector>
|
||||
9
app/src/main/res/drawable/blue_ring_bg.xml
Normal file
9
app/src/main/res/drawable/blue_ring_bg.xml
Normal file
@ -0,0 +1,9 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="45dp"
|
||||
android:height="43dp"
|
||||
android:viewportWidth="45"
|
||||
android:viewportHeight="43">
|
||||
<path
|
||||
android:pathData="M22.5,43C34.926,43 45,33.374 45,21.5C45,9.626 34.926,0 22.5,0C10.074,0 0,9.626 0,21.5C0,33.374 10.074,43 22.5,43Z"
|
||||
android:fillColor="#2E4247"/>
|
||||
</vector>
|
||||
9
app/src/main/res/drawable/blue_roundend_rectangle.xml
Normal file
9
app/src/main/res/drawable/blue_roundend_rectangle.xml
Normal file
@ -0,0 +1,9 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="279dp"
|
||||
android:height="33dp"
|
||||
android:viewportWidth="279"
|
||||
android:viewportHeight="33">
|
||||
<path
|
||||
android:pathData="M16.5,0L262.5,0A16.5,16.5 0,0 1,279 16.5L279,16.5A16.5,16.5 0,0 1,262.5 33L16.5,33A16.5,16.5 0,0 1,0 16.5L0,16.5A16.5,16.5 0,0 1,16.5 0z"
|
||||
android:fillColor="#184857"/>
|
||||
</vector>
|
||||
9
app/src/main/res/drawable/cancel.xml
Normal file
9
app/src/main/res/drawable/cancel.xml
Normal file
@ -0,0 +1,9 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="10dp"
|
||||
android:height="11dp"
|
||||
android:viewportWidth="10"
|
||||
android:viewportHeight="11">
|
||||
<path
|
||||
android:pathData="M5.787,5.211L9.434,1.572C9.7,1.306 9.7,0.866 9.434,0.6C9.167,0.333 8.728,0.333 8.461,0.6L4.814,4.246L1.175,0.6C0.901,0.325 0.47,0.325 0.203,0.6C-0.064,0.874 -0.072,1.298 0.203,1.572L3.85,5.219L0.203,8.858C-0.064,9.124 -0.064,9.564 0.203,9.83C0.47,10.097 0.909,10.097 1.175,9.83L4.822,6.184L8.469,9.83C8.736,10.097 9.175,10.097 9.441,9.83C9.708,9.564 9.708,9.124 9.441,8.858L5.795,5.211H5.787Z"
|
||||
android:fillColor="#ADADAD"/>
|
||||
</vector>
|
||||
5
app/src/main/res/drawable/control_bar_bg.xml
Normal file
5
app/src/main/res/drawable/control_bar_bg.xml
Normal file
@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<solid android:color="#154756" />
|
||||
<corners android:radius="12dp" />
|
||||
</shape>
|
||||
9
app/src/main/res/drawable/control_setting.xml
Normal file
9
app/src/main/res/drawable/control_setting.xml
Normal file
@ -0,0 +1,9 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="14dp"
|
||||
android:height="15dp"
|
||||
android:viewportWidth="14"
|
||||
android:viewportHeight="15">
|
||||
<path
|
||||
android:pathData="M7.569,0C7.954,0 8.299,0.22 8.471,0.557L8.91,1.427C9.459,1.647 9.969,1.945 10.432,2.306L11.412,2.251C11.796,2.227 12.157,2.423 12.345,2.753L13.232,4.29C13.42,4.619 13.412,5.027 13.2,5.349L12.659,6.164C12.745,6.752 12.745,7.341 12.659,7.929L13.2,8.744C13.412,9.066 13.42,9.474 13.232,9.803L12.345,11.34C12.157,11.67 11.796,11.866 11.412,11.842L10.432,11.787C9.969,12.156 9.459,12.454 8.91,12.666L8.471,13.536C8.299,13.873 7.954,14.093 7.569,14.093H5.797C5.413,14.093 5.068,13.873 4.895,13.536L4.456,12.666C3.907,12.446 3.397,12.148 2.934,11.787L1.954,11.842C1.57,11.866 1.209,11.67 1.021,11.34L0.135,9.803C-0.054,9.474 -0.046,9.066 0.166,8.744L0.707,7.929C0.621,7.348 0.621,6.752 0.707,6.164L0.166,5.349C-0.046,5.027 -0.054,4.619 0.135,4.29L1.021,2.753C1.209,2.423 1.57,2.227 1.954,2.251L2.934,2.306C3.397,1.937 3.915,1.639 4.464,1.427L4.903,0.557C5.075,0.22 5.42,0 5.805,0H7.577L7.569,0ZM7.569,1.004H5.797L5.185,2.219L4.832,2.361C4.377,2.541 3.946,2.792 3.562,3.098L3.256,3.333L1.891,3.255L1.005,4.792L1.758,5.929L1.703,6.305C1.633,6.792 1.633,7.286 1.703,7.772L1.758,8.148L1.005,9.285L1.891,10.823L3.256,10.744L3.554,10.979C3.938,11.285 4.37,11.528 4.824,11.717L5.185,11.858L5.797,13.073H7.569L8.181,11.858L8.542,11.717C8.997,11.536 9.428,11.285 9.812,10.979L10.118,10.744L11.483,10.823L12.369,9.285L11.616,8.148L11.671,7.764C11.741,7.278 11.741,6.784 11.671,6.29L11.616,5.905L12.369,4.768L11.483,3.231L10.118,3.31L9.812,3.074C9.428,2.768 8.997,2.525 8.542,2.337L8.181,2.196L7.569,0.98V1.004ZM6.683,4.525C8.071,4.525 9.201,5.654 9.201,7.043C9.201,8.431 8.071,9.56 6.683,9.56C5.295,9.56 4.166,8.431 4.166,7.043C4.166,5.654 5.295,4.525 6.683,4.525ZM6.683,5.529C5.852,5.529 5.17,6.203 5.17,7.043C5.17,7.882 5.844,8.556 6.683,8.556C7.522,8.556 8.197,7.882 8.197,7.043C8.197,6.203 7.522,5.529 6.683,5.529Z"
|
||||
android:fillColor="#F9F9F9"/>
|
||||
</vector>
|
||||
9
app/src/main/res/drawable/cut_off_line.xml
Normal file
9
app/src/main/res/drawable/cut_off_line.xml
Normal file
@ -0,0 +1,9 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="34dp"
|
||||
android:height="2dp"
|
||||
android:viewportWidth="34"
|
||||
android:viewportHeight="2">
|
||||
<path
|
||||
android:pathData="M33.943,1.023H0.057C0.025,1.023 0,0.849 0,0.628C0,0.406 0.025,0.232 0.057,0.232H33.943C33.975,0.232 34,0.406 34,0.628C34,0.849 33.975,1.023 33.943,1.023Z"
|
||||
android:fillColor="#ADADAD"/>
|
||||
</vector>
|
||||
9
app/src/main/res/drawable/cycle.xml
Normal file
9
app/src/main/res/drawable/cycle.xml
Normal file
@ -0,0 +1,9 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="12dp"
|
||||
android:height="12dp"
|
||||
android:viewportWidth="12"
|
||||
android:viewportHeight="12">
|
||||
<path
|
||||
android:pathData="M6.12,1.09C7.66,1.09 9.11,1.78 10.07,2.97H9.42C9.22,2.97 9.04,3.07 8.94,3.24C8.84,3.41 8.84,3.62 8.94,3.78C9.04,3.95 9.22,4.05 9.42,4.05H11.08C11.39,4.05 11.63,3.81 11.63,3.51V1.53C11.63,1.23 11.38,0.99 11.08,0.99C10.78,0.99 10.53,1.23 10.53,1.53V1.83C9.37,0.66 7.78,0 6.12,0C2.74,0 0,2.68 0,5.98C0,9.28 2.74,11.96 6.12,11.96C8.5,11.96 10.56,10.63 11.57,8.7C11.66,8.53 11.65,8.32 11.54,8.16C11.43,8 11.24,7.9 11.05,7.91C10.85,7.91 10.68,8.03 10.58,8.21C9.72,9.85 8,10.88 6.12,10.88C3.35,10.88 1.11,8.69 1.11,5.98C1.11,3.27 3.35,1.09 6.12,1.09Z"
|
||||
android:fillColor="#53747C"/>
|
||||
</vector>
|
||||
13
app/src/main/res/drawable/dash_line_1.xml
Normal file
13
app/src/main/res/drawable/dash_line_1.xml
Normal file
@ -0,0 +1,13 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="43dp"
|
||||
android:height="2dp"
|
||||
android:viewportWidth="43"
|
||||
android:viewportHeight="2">
|
||||
<path
|
||||
android:strokeWidth="1"
|
||||
android:pathData="M1,1H42"
|
||||
android:strokeAlpha="0.56"
|
||||
android:fillColor="#00000000"
|
||||
android:strokeColor="#ffffff"
|
||||
android:strokeLineCap="round"/>
|
||||
</vector>
|
||||
25
app/src/main/res/drawable/detection.xml
Normal file
25
app/src/main/res/drawable/detection.xml
Normal file
@ -0,0 +1,25 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="13dp"
|
||||
android:height="10dp"
|
||||
android:viewportWidth="13"
|
||||
android:viewportHeight="10">
|
||||
<group>
|
||||
<clip-path
|
||||
android:pathData="M0,0h12.92v9.92h-12.92z"/>
|
||||
<path
|
||||
android:pathData="M2.52,0.61C2.66,0.47 2.66,0.24 2.52,0.1C2.38,-0.04 2.15,-0.04 2.01,0.1C0.71,1.4 0,3.13 0,4.96C0,6.79 0.71,8.52 2.01,9.82C2.15,9.96 2.38,9.96 2.52,9.82C2.59,9.75 2.63,9.66 2.63,9.57C2.63,9.48 2.59,9.39 2.52,9.32C0.12,6.91 0.12,3.01 2.52,0.61Z"
|
||||
android:fillColor="#53747C"/>
|
||||
<path
|
||||
android:pathData="M2.62,4.96C2.62,3.83 3.06,2.76 3.86,1.96C3.93,1.89 3.97,1.8 3.97,1.71C3.97,1.62 3.93,1.53 3.86,1.46C3.72,1.32 3.49,1.32 3.35,1.46C2.41,2.4 1.89,3.65 1.89,4.97C1.89,6.29 2.41,7.54 3.35,8.48C3.49,8.62 3.72,8.62 3.86,8.48C4,8.34 4,8.11 3.86,7.97C3.06,7.17 2.62,6.1 2.62,4.97V4.96Z"
|
||||
android:fillColor="#53747C"/>
|
||||
<path
|
||||
android:pathData="M5.14,2.72C5,2.58 4.77,2.58 4.63,2.72C3.39,3.96 3.39,5.97 4.63,7.2C4.77,7.34 5,7.34 5.14,7.2C5.21,7.13 5.25,7.04 5.25,6.95C5.25,6.86 5.21,6.77 5.14,6.7C4.19,5.75 4.19,4.19 5.14,3.24C5.28,3.1 5.28,2.87 5.14,2.73V2.72ZM6.46,4.09C5.98,4.09 5.59,4.48 5.59,4.96C5.59,5.44 5.98,5.83 6.46,5.83C6.94,5.83 7.33,5.44 7.33,4.96C7.33,4.48 6.94,4.09 6.46,4.09ZM10.91,0.11C10.77,-0.03 10.54,-0.03 10.4,0.11C10.26,0.25 10.26,0.48 10.4,0.62C12.8,3.02 12.8,6.92 10.4,9.31C10.33,9.38 10.29,9.47 10.29,9.56C10.29,9.65 10.33,9.74 10.4,9.81C10.54,9.95 10.77,9.95 10.91,9.81C12.21,8.51 12.92,6.79 12.92,4.95C12.92,3.11 12.2,1.4 10.91,0.11Z"
|
||||
android:fillColor="#53747C"/>
|
||||
<path
|
||||
android:pathData="M9.56,1.45C9.42,1.31 9.19,1.31 9.05,1.45C8.98,1.52 8.94,1.61 8.94,1.7C8.94,1.79 8.98,1.88 9.05,1.95C9.85,2.75 10.29,3.82 10.29,4.95C10.29,6.08 9.85,7.15 9.05,7.95C8.91,8.09 8.91,8.32 9.05,8.46C9.19,8.6 9.42,8.6 9.56,8.46C10.5,7.52 11.02,6.27 11.02,4.95C11.02,3.63 10.5,2.38 9.56,1.44V1.45Z"
|
||||
android:fillColor="#53747C"/>
|
||||
<path
|
||||
android:pathData="M8.29,2.72C8.15,2.58 7.92,2.58 7.78,2.72C7.64,2.86 7.64,3.09 7.78,3.23C8.73,4.18 8.73,5.74 7.78,6.69C7.71,6.76 7.67,6.85 7.67,6.94C7.67,7.03 7.71,7.12 7.78,7.19C7.92,7.33 8.15,7.33 8.29,7.19C9.53,5.95 9.53,3.94 8.29,2.71V2.72Z"
|
||||
android:fillColor="#53747C"/>
|
||||
</group>
|
||||
</vector>
|
||||
12
app/src/main/res/drawable/eye.xml
Normal file
12
app/src/main/res/drawable/eye.xml
Normal file
@ -0,0 +1,12 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="16dp"
|
||||
android:height="9dp"
|
||||
android:viewportWidth="16"
|
||||
android:viewportHeight="9">
|
||||
<path
|
||||
android:pathData="M7.623,8.376C3.349,8.376 0,6.541 0,4.188C0,1.835 3.349,0 7.623,0C11.897,0 15.246,1.843 15.246,4.188C15.246,6.533 11.897,8.376 7.623,8.376ZM7.623,0.729C3.89,0.729 0.729,2.314 0.729,4.188C0.729,6.062 3.882,7.646 7.615,7.646C11.348,7.646 14.501,6.062 14.501,4.188C14.501,2.314 11.356,0.729 7.623,0.729Z"
|
||||
android:fillColor="#F9F9F9"/>
|
||||
<path
|
||||
android:pathData="M7.623,6.29C8.723,6.29 9.615,5.349 9.615,4.188C9.615,3.027 8.723,2.086 7.623,2.086C6.523,2.086 5.631,3.027 5.631,4.188C5.631,5.349 6.523,6.29 7.623,6.29Z"
|
||||
android:fillColor="#F9F9F9"/>
|
||||
</vector>
|
||||
9
app/src/main/res/drawable/hide_eye.xml
Normal file
9
app/src/main/res/drawable/hide_eye.xml
Normal file
@ -0,0 +1,9 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="16dp"
|
||||
android:height="6dp"
|
||||
android:viewportWidth="16"
|
||||
android:viewportHeight="6">
|
||||
<path
|
||||
android:pathData="M8,6C4.299,6 0,3.573 0,0.435C0,0.192 0.188,0 0.426,0C0.663,0 0.852,0.192 0.852,0.435C0.852,2.962 4.782,5.121 8,5.121C10.825,5.121 15.148,3.021 15.148,0.435C15.148,0.192 15.337,0 15.574,0C15.812,0 16,0.192 16,0.435C16,3.607 11.144,6 8,6Z"
|
||||
android:fillColor="#F9F9F9"/>
|
||||
</vector>
|
||||
12
app/src/main/res/drawable/hourglass.xml
Normal file
12
app/src/main/res/drawable/hourglass.xml
Normal file
@ -0,0 +1,12 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="11dp"
|
||||
android:height="12dp"
|
||||
android:viewportWidth="11"
|
||||
android:viewportHeight="12">
|
||||
<path
|
||||
android:pathData="M8.64,11.07V8.87C8.64,8.42 8.43,8 8.09,7.72L5.92,5.91L8.04,4.14H8.05C8.39,3.85 8.58,3.43 8.59,2.99V0.82H10.11C10.33,0.82 10.51,0.63 10.51,0.41C10.51,0.19 10.33,0 10.1,0H0.4C0.18,0 0,0.19 0,0.41C0,0.63 0.18,0.82 0.41,0.82H1.95V2.99C1.95,3.44 2.16,3.86 2.5,4.14L4.62,5.91L2.45,7.72H2.44C2.1,8.01 1.91,8.43 1.9,8.87V11.07H0.41C0.19,11.07 0.01,11.26 0.01,11.48C0.01,11.7 0.19,11.89 0.42,11.89H10.12C10.34,11.89 10.52,11.7 10.52,11.48C10.52,11.26 10.34,11.07 10.11,11.07H8.64ZM3.03,3.51H3.02C2.87,3.37 2.78,3.18 2.78,2.97V0.82H7.76V2.97C7.76,3.18 7.67,3.37 7.52,3.5H7.51L5.27,5.37L3.03,3.5V3.51Z"
|
||||
android:fillColor="#53747C"/>
|
||||
<path
|
||||
android:pathData="M4.002,3.09C4.462,3.47 5.442,4.29 5.442,4.29L6.882,3.09C6.882,3.09 6.902,3 6.852,3H4.042C4.042,3 3.972,3.06 4.012,3.09H4.002Z"
|
||||
android:fillColor="#53747C"/>
|
||||
</vector>
|
||||
19
app/src/main/res/drawable/left_swipe.xml
Normal file
19
app/src/main/res/drawable/left_swipe.xml
Normal file
@ -0,0 +1,19 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="20dp"
|
||||
android:height="11dp"
|
||||
android:viewportWidth="20"
|
||||
android:viewportHeight="11">
|
||||
<group>
|
||||
<clip-path
|
||||
android:pathData="M0,0h19.68v10.63h-19.68z"/>
|
||||
<path
|
||||
android:pathData="M7.58,10.63C7.45,10.63 7.32,10.59 7.2,10.52L0.03,5.74L0,5.31C0,5.06 0.12,4.82 0.33,4.68L7.21,0.11C7.52,-0.1 7.94,-0.01 8.15,0.3C8.36,0.61 8.27,1.04 7.96,1.24L1.85,5.31L7.96,9.38C8.27,9.59 8.36,10.01 8.15,10.32C8.02,10.52 7.8,10.62 7.58,10.62V10.63Z"
|
||||
android:fillColor="#2E4247"/>
|
||||
<path
|
||||
android:pathData="M13.29,10.63C13.16,10.63 13.03,10.59 12.91,10.52L5.73,5.75L5.7,5.32C5.7,5.07 5.82,4.83 6.03,4.69L12.92,0.11C13.23,-0.1 13.65,-0.01 13.86,0.3C14.07,0.61 13.98,1.04 13.67,1.24L7.56,5.31L13.67,9.37C13.98,9.58 14.07,10 13.86,10.31C13.73,10.51 13.51,10.61 13.29,10.61V10.63Z"
|
||||
android:fillColor="#17353A"/>
|
||||
<path
|
||||
android:pathData="M19,10.63C18.87,10.63 18.74,10.59 18.62,10.52L11.44,5.75L11.41,5.32C11.41,5.07 11.53,4.83 11.74,4.69L18.63,0.11C18.94,-0.1 19.36,-0.01 19.57,0.3C19.78,0.61 19.69,1.04 19.38,1.24L13.27,5.31L19.38,9.37C19.69,9.58 19.78,10 19.57,10.31C19.44,10.51 19.22,10.61 19,10.61V10.63Z"
|
||||
android:fillColor="#0D2D30"/>
|
||||
</group>
|
||||
</vector>
|
||||
13
app/src/main/res/drawable/line_4.xml
Normal file
13
app/src/main/res/drawable/line_4.xml
Normal file
@ -0,0 +1,13 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="43dp"
|
||||
android:height="2dp"
|
||||
android:viewportWidth="43"
|
||||
android:viewportHeight="2">
|
||||
<path
|
||||
android:strokeWidth="1"
|
||||
android:pathData="M1,1H42"
|
||||
android:strokeAlpha="0.56"
|
||||
android:fillColor="#00000000"
|
||||
android:strokeColor="#ffffff"
|
||||
android:strokeLineCap="round"/>
|
||||
</vector>
|
||||
14
app/src/main/res/drawable/notification.xml
Normal file
14
app/src/main/res/drawable/notification.xml
Normal file
@ -0,0 +1,14 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="32dp"
|
||||
android:height="32dp"
|
||||
android:viewportWidth="1024"
|
||||
android:viewportHeight="1024">
|
||||
<path
|
||||
android:pathData="M149.3,593.6v-8.7c1.5,-27.9 10.3,-55 25.6,-78.5a217.9,217.9 0,0 0,50.8 -100.5c1.9,-28.5 0,-57.6 1.9,-86.5C241.4,180.9 378.5,85.3 509.7,85.3h3.8c133.6,0 267.2,95.6 281.7,234 2.6,28.5 0,58 2.3,86.5a213.8,213.8 0,0 0,50.8 100.5c15.9,23.2 25,50.4 26.3,78.5v8.7a156.1,156.1 0,0 1,-38.2 103.2,191.3 191.3,0 0,1 -121.8,59.6 1609.4,1609.4 0,0 1,-409.6 0,191.3 191.3,0 0,1 -120.3,-59.6 153.7,153.7 0,0 1,-35.5 -103.2z"
|
||||
android:fillColor="#200E32"/>
|
||||
<path
|
||||
android:pathData="M561.6,814.7c-27.1,-1.9 -49.2,0 -71.4,0a270.8,270.8 0,0 0,-65.3 6.8c-18.3,4.2 -38.2,14.1 -38.2,34.9 1.9,20.2 12.9,38.4 29.8,49.7a158.8,158.8 0,0 0,114.5 31.4,133 133,0 0,0 98.9,-55.7 37.8,37.8 0,0 0,-6.5 -52.7,142 142,0 0,0 -61.9,-14.4z"
|
||||
android:strokeAlpha="0.4"
|
||||
android:fillColor="#200E32"
|
||||
android:fillAlpha="0.4"/>
|
||||
</vector>
|
||||
9
app/src/main/res/drawable/play.xml
Normal file
9
app/src/main/res/drawable/play.xml
Normal file
@ -0,0 +1,9 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="12dp"
|
||||
android:height="13dp"
|
||||
android:viewportWidth="12"
|
||||
android:viewportHeight="13">
|
||||
<path
|
||||
android:pathData="M11.764,6.462L5.882,3.231L0,0V6.462V12.924L5.882,9.693L11.764,6.462Z"
|
||||
android:fillColor="#0BC4FC"/>
|
||||
</vector>
|
||||
9
app/src/main/res/drawable/remove.xml
Normal file
9
app/src/main/res/drawable/remove.xml
Normal file
@ -0,0 +1,9 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="14dp"
|
||||
android:height="2dp"
|
||||
android:viewportWidth="14"
|
||||
android:viewportHeight="2">
|
||||
<path
|
||||
android:pathData="M12.657,0.511H1.169C0.793,0.511 0.489,0.814 0.489,1.188C0.489,1.561 0.793,1.864 1.169,1.864H12.657C13.033,1.864 13.337,1.561 13.337,1.188C13.337,0.814 13.033,0.511 12.657,0.511Z"
|
||||
android:fillColor="#F9F9F9"/>
|
||||
</vector>
|
||||
6
app/src/main/res/drawable/ring_has_bg.xml
Normal file
6
app/src/main/res/drawable/ring_has_bg.xml
Normal file
@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:drawable="@drawable/blue_ring_bg" />
|
||||
|
||||
<item android:drawable="@drawable/blue_ring" />
|
||||
</layer-list>
|
||||
@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<corners android:radius="21dp"/> <stroke
|
||||
android:width="1dp" android:color="#555555"/> </shape>
|
||||
@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<corners android:radius="8dp" />
|
||||
<stroke
|
||||
android:width="1dp"
|
||||
android:color="#4A5560"
|
||||
android:dashWidth="4dp"
|
||||
android:dashGap="4dp" />
|
||||
<solid android:color="@color/bg_blue" />
|
||||
</shape>
|
||||
9
app/src/main/res/drawable/save.xml
Normal file
9
app/src/main/res/drawable/save.xml
Normal file
@ -0,0 +1,9 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="15dp"
|
||||
android:height="15dp"
|
||||
android:viewportWidth="15"
|
||||
android:viewportHeight="15">
|
||||
<path
|
||||
android:pathData="M13.858,3.733L10.838,0.714L10.227,0.102C10.164,0.031 10.07,0 9.976,0H1.67C0.745,0 0,0.745 0,1.663V12.901C0,13.818 0.745,14.571 1.663,14.571H12.901C13.818,14.571 14.564,13.826 14.564,12.909V4.596C14.564,4.502 14.524,4.407 14.462,4.345L13.85,3.733H13.858ZM3.098,13.858V8.572C3.098,8.046 3.521,7.623 4.047,7.623H10.517C11.042,7.623 11.466,8.046 11.466,8.572V13.858H3.098ZM13.85,12.909C13.85,13.434 13.426,13.858 12.901,13.858H12.179V8.572C12.179,7.654 11.434,6.909 10.517,6.909H4.055C3.137,6.909 2.392,7.654 2.392,8.572V13.858H1.67C1.145,13.858 0.722,13.434 0.722,12.909V1.663C0.722,1.137 1.145,0.714 1.67,0.714H2.392V3.161C2.392,4.078 3.137,4.823 4.055,4.823H9.333C9.529,4.823 9.693,4.666 9.693,4.462C9.693,4.258 9.536,4.102 9.333,4.102H4.055C3.529,4.102 3.106,3.678 3.106,3.153V0.714H9.685C9.78,0.714 9.874,0.753 9.936,0.816L13.756,4.635C13.826,4.705 13.858,4.792 13.858,4.886V12.901L13.85,12.909Z"
|
||||
android:fillColor="#F9F9F9"/>
|
||||
</vector>
|
||||
15
app/src/main/res/drawable/seek_bar_color_white.xml
Normal file
15
app/src/main/res/drawable/seek_bar_color_white.xml
Normal file
@ -0,0 +1,15 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:id="@android:id/background">
|
||||
<shape>
|
||||
<corners android:radius="5dp" />
|
||||
<solid android:color="#3D5C63" /> </shape>
|
||||
</item>
|
||||
<item android:id="@android:id/progress">
|
||||
<clip>
|
||||
<shape>
|
||||
<corners android:radius="5dp" />
|
||||
<solid android:color="@android:color/white" /> </shape>
|
||||
</clip>
|
||||
</item>
|
||||
</layer-list>
|
||||
4
app/src/main/res/drawable/seekbar_thumb_white.xml
Normal file
4
app/src/main/res/drawable/seekbar_thumb_white.xml
Normal file
@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="oval">
|
||||
<size android:width="20dp" android:height="20dp"/> <solid android:color="@android:color/white"/> <stroke android:width="2dp" android:color="#80FFFFFF"/> </shape>
|
||||
12
app/src/main/res/drawable/slide.xml
Normal file
12
app/src/main/res/drawable/slide.xml
Normal file
@ -0,0 +1,12 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="18dp"
|
||||
android:height="18dp"
|
||||
android:viewportWidth="18"
|
||||
android:viewportHeight="18">
|
||||
<path
|
||||
android:pathData="M8.972,9.083L8.782,9.439L6.679,12.965L13.511,9.209L6.75,5.493L8.972,9.083Z"
|
||||
android:fillColor="#F9F9F9"/>
|
||||
<path
|
||||
android:pathData="M9.209,0.907C4.623,0.907 0.907,4.623 0.907,9.209C0.907,13.795 4.623,17.511 9.209,17.511C13.795,17.511 17.512,13.795 17.512,9.209C17.512,4.623 13.795,0.907 9.209,0.907ZM14.958,9.771L5.09,15.195L4.726,14.863C4.528,14.657 4.489,14.341 4.639,14.096L7.596,9.122L4.402,3.959L4.718,3.572C4.916,3.358 5.232,3.311 5.485,3.445L15.266,8.814L15.29,9.557L14.958,9.763V9.771Z"
|
||||
android:fillColor="#F9F9F9"/>
|
||||
</vector>
|
||||
9
app/src/main/res/drawable/stop.xml
Normal file
9
app/src/main/res/drawable/stop.xml
Normal file
@ -0,0 +1,9 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="14dp"
|
||||
android:height="14dp"
|
||||
android:viewportWidth="14"
|
||||
android:viewportHeight="14">
|
||||
<path
|
||||
android:pathData="M2,0L12,0A2,2 0,0 1,14 2L14,12A2,2 0,0 1,12 14L2,14A2,2 0,0 1,0 12L0,2A2,2 0,0 1,2 0z"
|
||||
android:fillColor="#E83434"/>
|
||||
</vector>
|
||||
9
app/src/main/res/drawable/touch_point.xml
Normal file
9
app/src/main/res/drawable/touch_point.xml
Normal file
@ -0,0 +1,9 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="32dp"
|
||||
android:height="32dp"
|
||||
android:viewportWidth="1024"
|
||||
android:viewportHeight="1024">
|
||||
<path
|
||||
android:pathData="M502.7,448a56,56 0,1 0,0 112,56 56,0 0,0 0,-112zM502.7,96C277.3,96 94.6,278.7 94.6,504S277.3,912 502.6,912C728,912 910.7,729.3 910.7,504S728,96 502.7,96zM544,829.3L544,688h-80v141.3C320,811.1 195.5,688 177.3,544L320,544v-80h-142.7C195.5,320 320,196.8 464,178.7L464,320h80v-141.3C688,196.8 809.8,320 828,464L688,464v80h140C809.8,688 688,811.2 544,829.3z"
|
||||
android:fillColor="#FF0057"/>
|
||||
</vector>
|
||||
9
app/src/main/res/drawable/un_touch_point.xml
Normal file
9
app/src/main/res/drawable/un_touch_point.xml
Normal file
@ -0,0 +1,9 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="47dp"
|
||||
android:height="47dp"
|
||||
android:viewportWidth="47"
|
||||
android:viewportHeight="47">
|
||||
<path
|
||||
android:pathData="M23.5,0C10.522,0 0,10.522 0,23.5C0,36.478 10.522,47 23.5,47C36.478,47 47,36.478 47,23.5C47,10.522 36.478,0 23.5,0ZM23.743,44.908C23.743,44.908 23.788,44.786 23.788,44.726V40.177C23.788,39.601 23.318,39.146 22.757,39.146C22.196,39.146 21.726,39.617 21.726,40.177V44.726C21.726,44.726 21.741,44.802 21.741,44.832C11.098,43.953 2.653,35.265 2.138,24.531H6.08C6.656,24.531 7.111,24.061 7.111,23.5C7.111,22.939 6.641,22.469 6.08,22.469H2.123C2.638,11.72 11.083,3.047 21.726,2.168C21.726,2.214 21.711,2.244 21.711,2.274V6.823C21.711,7.399 22.181,7.854 22.742,7.854C23.303,7.854 23.773,7.384 23.773,6.823V2.274C23.773,2.274 23.743,2.153 23.727,2.092C35.083,2.214 44.317,11.219 44.862,22.469H40.92C40.344,22.469 39.889,22.939 39.889,23.5C39.889,24.061 40.359,24.531 40.92,24.531H44.862C44.317,35.781 35.083,44.786 23.727,44.908H23.743Z"
|
||||
android:fillColor="#0BC4FC"/>
|
||||
</vector>
|
||||
13
app/src/main/res/drawable/white_arrow_right.xml
Normal file
13
app/src/main/res/drawable/white_arrow_right.xml
Normal file
@ -0,0 +1,13 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="9dp"
|
||||
android:height="14dp"
|
||||
android:viewportWidth="9"
|
||||
android:viewportHeight="14">
|
||||
<group>
|
||||
<clip-path
|
||||
android:pathData="M0,0h9v14h-9z"/>
|
||||
<path
|
||||
android:pathData="M9,6.998L4.5,10.499L0,14L2.767,6.998L0,0L4.5,3.501L9,6.998Z"
|
||||
android:fillColor="#ffffff"/>
|
||||
</group>
|
||||
</vector>
|
||||
@ -7,7 +7,7 @@
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/black"
|
||||
android:padding="24dp"
|
||||
tools:context=".presentation.ui.activity.AccessibilityActivity">
|
||||
tools:context=".ui.activity.main.AccessibilityActivity">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/title"
|
||||
|
||||
@ -6,7 +6,7 @@
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:padding="24dp"
|
||||
tools:context=".presentation.ui.activity.welcome.AgreementActivity">
|
||||
tools:context=".ui.activity.welcome.AgreementActivity">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/logoImageView"
|
||||
|
||||
98
app/src/main/res/layout/activity_battery_limit_free.xml
Normal file
98
app/src/main/res/layout/activity_battery_limit_free.xml
Normal file
@ -0,0 +1,98 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:id="@+id/main"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".ui.activity.menu.BatteryLimitFreeActivity">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/battery_lim"
|
||||
android:layout_width="231dp"
|
||||
android:layout_height="53dp"
|
||||
android:layout_marginTop="28dp"
|
||||
android:gravity="center"
|
||||
android:text=" Battery limit Free"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="28sp"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<ImageView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="23dp"
|
||||
android:src="@drawable/back"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/battery_lim"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/battery_lim" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/info_card"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="19dp"
|
||||
android:layout_marginTop="23dp"
|
||||
android:layout_marginEnd="19dp"
|
||||
android:background="@drawable/bg_rounded_rect"
|
||||
android:orientation="vertical"
|
||||
android:padding="16dp"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/battery_lim">
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="start"
|
||||
android:text="@string/app_was_forcibly_stopped"
|
||||
android:textColor="@color/white"
|
||||
android:textStyle="bold"
|
||||
android:textSize="17sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:gravity="start"
|
||||
android:text="if the app does not work, you can try these
|
||||
solutions."
|
||||
android:textColor="@color/text_gray"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="22dp"
|
||||
android:gravity="start"
|
||||
android:text="1. First click on Grant option.
|
||||
\n2. Disable Accessibility service then enable
|
||||
\nit again."
|
||||
android:textColor="@color/text_gray"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="22dp"
|
||||
android:gravity="start"
|
||||
android:text="If problem is not resolve then restart
|
||||
\nyour phone. For more details tell us via
|
||||
Feedback"
|
||||
android:textColor="@color/text_gray"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<Button
|
||||
android:layout_width="127dp"
|
||||
android:layout_height="42dp"
|
||||
android:layout_gravity="center"
|
||||
android:layout_marginTop="30dp"
|
||||
android:backgroundTint="@color/blue"
|
||||
android:text="Grant"
|
||||
android:textSize="18sp" />
|
||||
</LinearLayout>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
203
app/src/main/res/layout/activity_feedback.xml
Normal file
203
app/src/main/res/layout/activity_feedback.xml
Normal file
@ -0,0 +1,203 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:id="@+id/main"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".ui.activity.menu.FeedbackActivity">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/back_arrow"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="23dp"
|
||||
android:src="@drawable/back"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/feedback_title"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/feedback_title"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/feedback_title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="60dp"
|
||||
android:layout_marginTop="28dp"
|
||||
android:text="Feedback"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="28sp"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<androidx.cardview.widget.CardView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_marginStart="14dp"
|
||||
android:layout_marginEnd="14dp"
|
||||
android:layout_marginBottom="44dp"
|
||||
android:backgroundTint="@color/bg_blue"
|
||||
app:cardCornerRadius="8dp"
|
||||
app:cardElevation="0dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/feedback_title"
|
||||
app:layout_constraintVertical_bias="0.0"
|
||||
tools:layout_editor_absoluteX="0dp">
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@drawable/bg_rounded_rect"
|
||||
android:paddingStart="20dp">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/problem_description_title"
|
||||
android:layout_width="233dp"
|
||||
android:layout_height="48dp"
|
||||
android:layout_marginTop="24dp"
|
||||
android:text="Tell us the problem you \n
|
||||
Encountered"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="21sp"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/category_label"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="16dp"
|
||||
android:text="Category"
|
||||
android:textColor="#9DBDC9"
|
||||
android:textSize="16sp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/problem_description_title" />
|
||||
|
||||
<androidx.constraintlayout.helper.widget.Flow
|
||||
android:id="@+id/category_flow"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
app:constraint_referenced_ids="btn_overall_service,btn_speed_efficiency,btn_too_many_ads,btn_customer_support,btn_app_crash,btn_new_feature"
|
||||
app:flow_horizontalGap="8dp"
|
||||
app:flow_verticalGap="8dp"
|
||||
app:flow_wrapMode="aligned"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/category_label" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/btn_overall_service"
|
||||
style="@style/Widget.MaterialComponents.Button.OutlinedButton"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:backgroundTint="@color/button_gray"
|
||||
android:text="Overall Service"
|
||||
android:textAllCaps="false"
|
||||
android:textColor="#608E9E"
|
||||
android:textSize="12sp"
|
||||
app:cornerRadius="20dp" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/btn_speed_efficiency"
|
||||
style="@style/Widget.MaterialComponents.Button.OutlinedButton"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:backgroundTint="@color/button_gray"
|
||||
android:text="Speed & Efficiency"
|
||||
android:textAllCaps="false"
|
||||
android:textColor="#608E9E"
|
||||
android:textSize="12sp"
|
||||
app:cornerRadius="20dp" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/btn_too_many_ads"
|
||||
style="@style/Widget.MaterialComponents.Button.OutlinedButton"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:backgroundTint="@color/button_gray"
|
||||
android:text="Too Many Ads"
|
||||
android:textAllCaps="false"
|
||||
android:textColor="#608E9E"
|
||||
android:textSize="12sp"
|
||||
app:cornerRadius="20dp" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/btn_customer_support"
|
||||
style="@style/Widget.MaterialComponents.Button.OutlinedButton"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:backgroundTint="@color/button_gray"
|
||||
android:text="Customer Support"
|
||||
android:textAllCaps="false"
|
||||
android:textColor="#608E9E"
|
||||
android:textSize="12sp"
|
||||
app:cornerRadius="20dp" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/btn_app_crash"
|
||||
style="@style/Widget.MaterialComponents.Button.OutlinedButton"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:backgroundTint="@color/button_gray"
|
||||
android:text="App Crash"
|
||||
android:textAllCaps="false"
|
||||
android:textColor="#608E9E"
|
||||
android:textSize="12sp"
|
||||
app:cornerRadius="20dp" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/btn_new_feature"
|
||||
style="@style/Widget.MaterialComponents.Button.OutlinedButton"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:backgroundTint="@color/button_gray"
|
||||
android:text="New Feature"
|
||||
android:textAllCaps="false"
|
||||
android:textColor="#608E9E"
|
||||
android:textSize="12sp"
|
||||
app:cornerRadius="20dp" />
|
||||
|
||||
<EditText
|
||||
android:id="@+id/problem_description_edittext"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_marginTop="16dp"
|
||||
android:layout_marginEnd="20dp"
|
||||
android:layout_marginBottom="28dp"
|
||||
android:background="@drawable/rounded_edittext_dotted_background"
|
||||
android:gravity="top|start"
|
||||
android:hint="Please describe your problem"
|
||||
android:inputType="textMultiLine"
|
||||
android:maxLines="10"
|
||||
android:minLines="5"
|
||||
android:padding="12dp"
|
||||
android:textColor="#608E9E"
|
||||
android:textColorHint="#B0BEC5"
|
||||
android:textSize="12sp"
|
||||
app:layout_constraintBottom_toTopOf="@id/submit_button"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/category_flow" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/submit_button"
|
||||
android:layout_width="257dp"
|
||||
android:layout_height="52dp"
|
||||
android:layout_marginBottom="31dp"
|
||||
android:backgroundTint="@color/blue"
|
||||
android:text="Submit"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="21sp"
|
||||
android:textStyle="bold"
|
||||
app:cornerRadius="8dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
</androidx.cardview.widget.CardView>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
50
app/src/main/res/layout/activity_how_to_use.xml
Normal file
50
app/src/main/res/layout/activity_how_to_use.xml
Normal file
@ -0,0 +1,50 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:id="@+id/main"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".ui.activity.menu.HowToUseActivity">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/back"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="23dp"
|
||||
android:src="@drawable/back"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/how_title"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/how_title"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/how_title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="60dp"
|
||||
android:layout_marginTop="28dp"
|
||||
android:text="How to Use"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="28sp"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<com.google.android.material.tabs.TabLayout
|
||||
android:id="@+id/how_tablayout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="88dp"
|
||||
android:layout_marginTop="8dp"
|
||||
android:background="@android:color/transparent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/how_title"
|
||||
app:tabRippleColor="@android:color/transparent" />
|
||||
|
||||
<androidx.viewpager2.widget.ViewPager2
|
||||
android:id="@+id/how_viewpager"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/how_tablayout" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@ -5,6 +5,6 @@
|
||||
android:id="@+id/main"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".presentation.ui.activity.welcome.LauncherActivity">
|
||||
tools:context=".ui.activity.welcome.LauncherActivity">
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@ -5,27 +5,27 @@
|
||||
android:id="@+id/main"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".presentation.ui.activity.MainActivity">
|
||||
tools:context=".ui.activity.main.MainActivity">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/menu"
|
||||
android:layout_width="24dp"
|
||||
android:layout_height="24dp"
|
||||
android:src="@drawable/menu"
|
||||
android:layout_marginStart="24dp"
|
||||
android:src="@drawable/menu"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/title"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/title"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/title"/>
|
||||
app:layout_constraintTop_toTopOf="@+id/title" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/setting"
|
||||
android:layout_width="24dp"
|
||||
android:layout_height="24dp"
|
||||
android:src="@drawable/setting"
|
||||
android:layout_marginEnd="24dp"
|
||||
android:src="@drawable/setting"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/title"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/title"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/title" />
|
||||
app:layout_constraintTop_toTopOf="@+id/title" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/title"
|
||||
@ -49,46 +49,25 @@
|
||||
app:layout_constraintEnd_toEndOf="@id/setting"
|
||||
app:layout_constraintTop_toBottomOf="@id/setting" />
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/circle_container"
|
||||
<VideoView
|
||||
android:id="@+id/animated_video"
|
||||
android:layout_width="350dp"
|
||||
android:layout_height="350dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/title"
|
||||
app:layout_constraintVertical_bias="0.3">
|
||||
app:layout_constraintVertical_bias="0.3" />
|
||||
|
||||
<ImageView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:src="@drawable/light_glow" />
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="200dp"
|
||||
android:layout_height="200dp"
|
||||
android:layout_gravity="center"
|
||||
android:background="@drawable/circle_background"
|
||||
android:gravity="center"
|
||||
android:orientation="vertical">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/center_icon"
|
||||
android:layout_width="72dp"
|
||||
android:layout_height="72dp"
|
||||
android:layout_marginTop="16dp"
|
||||
android:src="@drawable/ic_switch" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/center_text"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:text="@string/start"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="32sp" />
|
||||
</LinearLayout>
|
||||
</FrameLayout>
|
||||
<View
|
||||
android:id="@+id/animated_view"
|
||||
android:layout_width="350dp"
|
||||
android:layout_height="350dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/title"
|
||||
app:layout_constraintVertical_bias="0.3" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/button_container"
|
||||
@ -102,7 +81,7 @@
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/circle_container">
|
||||
app:layout_constraintTop_toBottomOf="@id/animated_video">
|
||||
|
||||
<androidx.appcompat.widget.AppCompatButton
|
||||
android:id="@+id/single"
|
||||
|
||||
@ -5,7 +5,7 @@
|
||||
android:layout_height="match_parent"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:id="@+id/main"
|
||||
tools:context=".presentation.ui.activity.menu.MenuActivity">
|
||||
tools:context=".ui.activity.menu.MenuActivity">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
|
||||
58
app/src/main/res/layout/activity_question.xml
Normal file
58
app/src/main/res/layout/activity_question.xml
Normal file
@ -0,0 +1,58 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:id="@+id/main"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".ui.activity.main.QuestionActivity">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/single_poin"
|
||||
android:layout_width="160dp"
|
||||
android:layout_height="53dp"
|
||||
android:layout_marginTop="29dp"
|
||||
android:gravity="center"
|
||||
android:text="Single-Point"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="28sp"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/click_on_st"
|
||||
android:layout_width="290dp"
|
||||
android:layout_height="18dp"
|
||||
android:layout_marginTop="48dp"
|
||||
android:text="@string/_1_click_on_quot_start_quot_button_to_run_the_service"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/single_poin" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/drag_the_ac"
|
||||
android:layout_width="284dp"
|
||||
android:layout_height="36dp"
|
||||
android:layout_marginTop="16dp"
|
||||
android:text="@string/_2_drag_the_quot_action_point_quot_to_move_it_where_nyou_want_to_click"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toStartOf="@+id/click_on_st"
|
||||
app:layout_constraintTop_toBottomOf="@+id/click_on_st" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/click_play_"
|
||||
android:layout_width="198dp"
|
||||
android:layout_height="18dp"
|
||||
android:layout_marginTop="16dp"
|
||||
android:text="@string/_3_click_quot_play_quot_to_start_clicking"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toStartOf="@id/click_on_st"
|
||||
app:layout_constraintTop_toBottomOf="@+id/drag_the_ac" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@ -5,7 +5,7 @@
|
||||
android:id="@+id/main"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".presentation.ui.activity.menu.ScriptsActivity">
|
||||
tools:context=".ui.activity.menu.ScriptsActivity">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/btn_back"
|
||||
|
||||
@ -1,10 +1,50 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:id="@+id/main"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".presentation.ui.activity.setting.SettingActivity">
|
||||
tools:context=".ui.activity.setting.SettingActivity">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/back"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="23dp"
|
||||
android:src="@drawable/back"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/setting_title"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/setting_title"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/setting_title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="60dp"
|
||||
android:layout_marginTop="28dp"
|
||||
android:text="Settings"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="28sp"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<com.google.android.material.tabs.TabLayout
|
||||
android:id="@+id/setting_tablayout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="88dp"
|
||||
android:layout_marginTop="8dp"
|
||||
android:background="@android:color/transparent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/setting_title"
|
||||
app:tabRippleColor="@android:color/transparent" />
|
||||
|
||||
<androidx.viewpager2.widget.ViewPager2
|
||||
android:id="@+id/setting_viewpager"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/setting_tablayout" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@ -5,7 +5,7 @@
|
||||
android:id="@+id/main"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".presentation.ui.activity.welcome.SplashActivity">
|
||||
tools:context=".ui.activity.welcome.SplashActivity">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/image"
|
||||
|
||||
75
app/src/main/res/layout/activity_troubleshooting.xml
Normal file
75
app/src/main/res/layout/activity_troubleshooting.xml
Normal file
@ -0,0 +1,75 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:id="@+id/main"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".ui.activity.menu.TroubleshootingActivity">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/battery_lim"
|
||||
android:layout_width="231dp"
|
||||
android:layout_height="53dp"
|
||||
android:layout_marginTop="28dp"
|
||||
android:gravity="center"
|
||||
android:text=" Battery limit Free"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="28sp"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<ImageView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="23dp"
|
||||
android:src="@drawable/back"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/battery_lim"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/battery_lim" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/info_card"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="19dp"
|
||||
android:layout_marginTop="23dp"
|
||||
android:layout_marginEnd="19dp"
|
||||
android:background="@drawable/bg_rounded_rect"
|
||||
android:orientation="vertical"
|
||||
android:padding="16dp"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/battery_lim">
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="start"
|
||||
android:text="Auto Clicker does not work"
|
||||
android:textStyle="bold"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="17sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:gravity="start"
|
||||
android:text="@string/enable_this_permission_to_run_the_app_in_the_background_under_ultra_power_saving_mode_grant"
|
||||
android:textColor="@color/text_gray"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<Button
|
||||
android:layout_width="127dp"
|
||||
android:layout_height="42dp"
|
||||
android:layout_gravity="center"
|
||||
android:layout_marginTop="11dp"
|
||||
android:backgroundTint="@color/blue"
|
||||
android:text="Regrant"
|
||||
android:textSize="18sp" />
|
||||
</LinearLayout>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
379
app/src/main/res/layout/fragment_action.xml
Normal file
379
app/src/main/res/layout/fragment_action.xml
Normal file
@ -0,0 +1,379 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.core.widget.NestedScrollView xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".ui.fragment.setting.ActionFragment">
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingBottom="25dp">
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/default_actions_container"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="223dp"
|
||||
android:layout_marginStart="20dp"
|
||||
android:layout_marginTop="14dp"
|
||||
android:layout_marginEnd="20dp"
|
||||
android:background="@drawable/bg_rounded_rect"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_default_actions_title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="15dp"
|
||||
android:layout_marginTop="9dp"
|
||||
android:text="Default Actions"
|
||||
android:textColor="@color/text_gray"
|
||||
android:textSize="15sp"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_interval_icon"
|
||||
android:layout_width="11dp"
|
||||
android:layout_height="12dp"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:src="@drawable/hourglass"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/tv_interval_label"
|
||||
app:layout_constraintEnd_toStartOf="@+id/tv_interval_label"
|
||||
app:layout_constraintTop_toTopOf="@+id/tv_interval_label" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_interval_label"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="36dp"
|
||||
android:layout_marginTop="9dp"
|
||||
android:text="Interval between actions"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/tv_default_actions_title" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/input_interval"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="42dp"
|
||||
android:layout_marginHorizontal="17dp"
|
||||
android:layout_marginTop="9dp"
|
||||
android:background="@drawable/rounded_edittext_background"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:paddingStart="12dp"
|
||||
android:paddingEnd="12dp"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/tv_interval_label">
|
||||
|
||||
<EditText
|
||||
android:id="@+id/et_interval_value"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:background="@null"
|
||||
android:inputType="number"
|
||||
android:padding="8dp"
|
||||
android:textColor="@color/white"
|
||||
android:textColorHint="@color/gray" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/interval_selector_container"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:clickable="true"
|
||||
android:focusable="true"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:paddingStart="12dp"
|
||||
android:paddingEnd="4dp">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/interval_selected_unit"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingEnd="4dp"
|
||||
android:text="milliseconds"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/interval_unit_dropdown"
|
||||
android:layout_width="15dp"
|
||||
android:layout_height="8dp"
|
||||
android:src="@drawable/blue_arrow_down" />
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/duration_icon"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="11dp"
|
||||
android:src="@drawable/left_swipe"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/tv_swipe_duration_label"
|
||||
app:layout_constraintEnd_toEndOf="@id/iv_interval_icon"
|
||||
app:layout_constraintTop_toTopOf="@id/tv_swipe_duration_label" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_swipe_duration_label"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="12dp"
|
||||
android:text="Swipe duration"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toStartOf="@+id/tv_interval_label"
|
||||
app:layout_constraintTop_toBottomOf="@id/input_interval" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_preview_label"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="41dp"
|
||||
android:text="@string/preview"
|
||||
android:textColor="@color/blue"
|
||||
android:textSize="12sp"
|
||||
app:layout_constraintBottom_toBottomOf="@id/tv_swipe_duration_label"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@id/tv_swipe_duration_label" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/input_with_unit_container"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="42dp"
|
||||
android:layout_marginHorizontal="17dp"
|
||||
android:layout_marginTop="8dp"
|
||||
android:layout_marginBottom="8dp"
|
||||
android:background="@drawable/rounded_edittext_background"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:paddingStart="12dp"
|
||||
android:paddingEnd="12dp"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/tv_swipe_duration_label">
|
||||
|
||||
<EditText
|
||||
android:id="@+id/et_duration_value"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:background="@null"
|
||||
android:inputType="number"
|
||||
android:padding="8dp"
|
||||
android:textColor="@color/white"
|
||||
android:textColorHint="@color/gray" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/unit_selector_container"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:clickable="true"
|
||||
android:focusable="true"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:paddingStart="12dp"
|
||||
android:paddingEnd="4dp">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_selected_unit"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingEnd="4dp"
|
||||
android:text="milliseconds"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_unit_dropdown"
|
||||
android:layout_width="15dp"
|
||||
android:layout_height="8dp"
|
||||
android:src="@drawable/blue_arrow_down" />
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/default_cycle_container"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="134dp"
|
||||
android:layout_marginHorizontal="20dp"
|
||||
android:layout_marginTop="23dp"
|
||||
android:background="@drawable/bg_rounded_rect"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/default_actions_container">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/default_cycle_title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="15dp"
|
||||
android:layout_marginTop="9dp"
|
||||
android:text="Default cycle"
|
||||
android:textColor="@color/text_gray"
|
||||
android:textSize="15sp"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/repeat_icon"
|
||||
android:layout_width="12dp"
|
||||
android:layout_height="12dp"
|
||||
android:layout_marginEnd="9dp"
|
||||
android:src="@drawable/cycle"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/repeat_text"
|
||||
app:layout_constraintEnd_toStartOf="@+id/repeat_text"
|
||||
app:layout_constraintTop_toTopOf="@+id/repeat_text" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/repeat_text"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="36dp"
|
||||
android:layout_marginTop="9dp"
|
||||
android:text="Repeat mode"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/default_cycle_title" />
|
||||
|
||||
<androidx.appcompat.widget.SwitchCompat
|
||||
android:id="@+id/repeat_switch"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="35dp"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/repeat_text"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/repeat_text"
|
||||
app:thumbTint="@color/switch_thumb_selector"
|
||||
app:trackTint="@color/switch_track_selector" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/repeat_input"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="48dp"
|
||||
android:layout_marginHorizontal="16dp"
|
||||
android:layout_marginTop="8dp"
|
||||
android:layout_marginBottom="8dp"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:paddingEnd="12dp"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/repeat_text">
|
||||
|
||||
<EditText
|
||||
android:id="@+id/et_repeat_value"
|
||||
android:layout_width="123dp"
|
||||
android:layout_height="42dp"
|
||||
android:background="@drawable/rounded_edittext_background"
|
||||
android:inputType="number"
|
||||
android:padding="8dp"
|
||||
android:textColor="@color/white"
|
||||
android:textColorHint="@color/gray" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/repeat_selector_container"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_marginStart="62dp"
|
||||
android:clickable="true"
|
||||
android:focusable="true"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:paddingStart="12dp"
|
||||
android:paddingEnd="4dp">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/repeat_selected_unit"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingEnd="4dp"
|
||||
android:text="infinitely"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/repeat_unit_dropdown"
|
||||
android:layout_width="15dp"
|
||||
android:layout_height="8dp"
|
||||
android:src="@drawable/blue_arrow_down" />
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/default_advanced_container"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="87dp"
|
||||
android:layout_marginHorizontal="20dp"
|
||||
android:layout_marginTop="20dp"
|
||||
android:background="@drawable/bg_rounded_rect"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/default_cycle_container">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/default_advanced_title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="15dp"
|
||||
android:layout_marginTop="9dp"
|
||||
android:text="Advanced"
|
||||
android:textColor="@color/text_gray"
|
||||
android:textSize="15sp"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/advanced_icon"
|
||||
android:layout_width="13dp"
|
||||
android:layout_height="10dp"
|
||||
android:layout_marginEnd="6dp"
|
||||
android:src="@drawable/detection"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/advanced_text"
|
||||
app:layout_constraintEnd_toStartOf="@+id/advanced_text"
|
||||
app:layout_constraintTop_toTopOf="@+id/advanced_text" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/advanced_text"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="36dp"
|
||||
android:layout_marginTop="9dp"
|
||||
android:text="Anti-Detection"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/default_advanced_title" />
|
||||
|
||||
<androidx.appcompat.widget.SwitchCompat
|
||||
android:id="@+id/advanced_switch"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="4dp"
|
||||
android:layout_marginEnd="35dp"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/advanced_text"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/advanced_text"
|
||||
app:thumbTint="@color/switch_thumb_selector"
|
||||
app:trackTint="@color/switch_track_selector" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
</androidx.core.widget.NestedScrollView>
|
||||
410
app/src/main/res/layout/fragment_how_multi.xml
Normal file
410
app/src/main/res/layout/fragment_how_multi.xml
Normal file
@ -0,0 +1,410 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.core.widget.NestedScrollView xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingBottom="25dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/left_control_bar"
|
||||
android:layout_width="34dp"
|
||||
android:layout_height="231dp"
|
||||
android:layout_marginStart="24dp"
|
||||
android:layout_marginTop="29dp"
|
||||
android:src="@mipmap/multi_control_bar"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text_play_stop"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="40dp"
|
||||
android:layout_marginTop="10dp"
|
||||
android:text="Play/Stop"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toEndOf="@+id/left_control_bar"
|
||||
app:layout_constraintTop_toTopOf="@+id/left_control_bar" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/dash_line_1"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="1dp"
|
||||
android:layout_marginEnd="6dp"
|
||||
android:src="@mipmap/line_1"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/text_play_stop"
|
||||
app:layout_constraintEnd_toStartOf="@+id/text_play_stop"
|
||||
app:layout_constraintStart_toEndOf="@+id/left_control_bar"
|
||||
app:layout_constraintTop_toTopOf="@+id/text_play_stop" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text_add_action"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="11dp"
|
||||
android:text="Add click action"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toStartOf="@+id/text_play_stop"
|
||||
app:layout_constraintTop_toBottomOf="@+id/text_play_stop" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/dash_line_2"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="1dp"
|
||||
android:layout_marginEnd="6dp"
|
||||
android:src="@mipmap/line_1"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/text_add_action"
|
||||
app:layout_constraintEnd_toStartOf="@+id/text_add_action"
|
||||
app:layout_constraintStart_toEndOf="@+id/left_control_bar"
|
||||
app:layout_constraintTop_toTopOf="@+id/text_add_action" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text_remove_action"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="6dp"
|
||||
android:text="Remove the last action"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toStartOf="@+id/text_play_stop"
|
||||
app:layout_constraintTop_toBottomOf="@+id/text_add_action" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/dash_line_3"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="1dp"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:src="@mipmap/line_1"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/text_remove_action"
|
||||
app:layout_constraintEnd_toStartOf="@+id/text_remove_action"
|
||||
app:layout_constraintStart_toEndOf="@+id/left_control_bar"
|
||||
app:layout_constraintTop_toTopOf="@+id/text_remove_action" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text_add_swipe"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="6dp"
|
||||
android:text="Add a swipe action"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toStartOf="@+id/text_play_stop"
|
||||
app:layout_constraintTop_toBottomOf="@+id/text_remove_action" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/dash_line_4"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="1dp"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:src="@mipmap/line_1"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/text_add_swipe"
|
||||
app:layout_constraintEnd_toStartOf="@+id/text_add_swipe"
|
||||
app:layout_constraintStart_toEndOf="@+id/left_control_bar"
|
||||
app:layout_constraintTop_toTopOf="@+id/text_add_swipe" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text_save"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="12dp"
|
||||
android:text="Save/Load scripts"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toStartOf="@+id/text_play_stop"
|
||||
app:layout_constraintTop_toBottomOf="@+id/text_add_swipe" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/dash_line_5"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="1dp"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:src="@mipmap/line_1"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/text_save"
|
||||
app:layout_constraintEnd_toStartOf="@+id/text_save"
|
||||
app:layout_constraintStart_toEndOf="@+id/left_control_bar"
|
||||
app:layout_constraintTop_toTopOf="@+id/text_save" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text_hide"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="6dp"
|
||||
android:text="Hide/Unhide"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toStartOf="@+id/text_play_stop"
|
||||
app:layout_constraintTop_toBottomOf="@+id/text_save" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/dash_line_6"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="1dp"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:src="@mipmap/line_1"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/text_hide"
|
||||
app:layout_constraintEnd_toStartOf="@+id/text_hide"
|
||||
app:layout_constraintStart_toEndOf="@+id/left_control_bar"
|
||||
app:layout_constraintTop_toTopOf="@+id/text_hide" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text_edit"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="7dp"
|
||||
android:text="Hide/Unhide"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toStartOf="@+id/text_play_stop"
|
||||
app:layout_constraintTop_toBottomOf="@+id/text_hide" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/dash_line_7"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="1dp"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:src="@mipmap/line_1"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/text_edit"
|
||||
app:layout_constraintEnd_toStartOf="@+id/text_edit"
|
||||
app:layout_constraintStart_toEndOf="@+id/left_control_bar"
|
||||
app:layout_constraintTop_toTopOf="@+id/text_edit" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text_stop"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
android:text="Stop service"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toStartOf="@+id/text_play_stop"
|
||||
app:layout_constraintTop_toBottomOf="@+id/text_edit" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/dash_line_8"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="1dp"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:src="@mipmap/line_1"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/text_stop"
|
||||
app:layout_constraintEnd_toStartOf="@+id/text_stop"
|
||||
app:layout_constraintStart_toEndOf="@+id/left_control_bar"
|
||||
app:layout_constraintTop_toTopOf="@+id/text_stop" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text_move_point"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="26dp"
|
||||
android:text="Drag the bar to move it anywhere"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toStartOf="@+id/text_play_stop"
|
||||
app:layout_constraintTop_toBottomOf="@+id/text_stop" />
|
||||
|
||||
<View
|
||||
android:id="@+id/left_bar_center_point_x"
|
||||
android:layout_width="1dp"
|
||||
android:layout_height="0dp"
|
||||
android:visibility="gone"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/left_control_bar"
|
||||
app:layout_constraintEnd_toEndOf="@+id/left_control_bar"
|
||||
app:layout_constraintStart_toStartOf="@+id/left_control_bar" />
|
||||
|
||||
<View
|
||||
android:id="@+id/text_point_center_point_y"
|
||||
android:layout_width="1dp"
|
||||
android:layout_height="0dp"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/text_move_point"
|
||||
app:layout_constraintEnd_toEndOf="@+id/text_move_point"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toStartOf="@+id/text_move_point"
|
||||
app:layout_constraintTop_toTopOf="@+id/text_move_point"
|
||||
app:layout_constraintVertical_bias="0.5" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/dash_line_0"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:src="@mipmap/line_2"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/text_point_center_point_y"
|
||||
app:layout_constraintEnd_toStartOf="@+id/text_move_point"
|
||||
app:layout_constraintStart_toStartOf="@+id/left_bar_center_point_x"
|
||||
app:layout_constraintTop_toBottomOf="@+id/left_control_bar" />
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/ring_with_text_container"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="19dp"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/text_action_point"
|
||||
app:layout_constraintEnd_toStartOf="@+id/text_action_point"
|
||||
app:layout_constraintTop_toTopOf="@+id/text_action_point">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ring"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/ring_has_bg"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/ring_text"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="1"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="26sp"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/ring"
|
||||
app:layout_constraintEnd_toEndOf="@+id/ring"
|
||||
app:layout_constraintStart_toStartOf="@+id/ring"
|
||||
app:layout_constraintTop_toTopOf="@+id/ring" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text_action_point"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="72dp"
|
||||
android:text="Drag the action point to move it
|
||||
\nanywhere, click to edit the interval"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
android:layout_marginStart="109dp"
|
||||
app:layout_constraintTop_toBottomOf="@+id/text_move_point" />
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/blue_rounded_rectangle"
|
||||
android:layout_width="279dp"
|
||||
android:layout_height="33dp"
|
||||
android:layout_marginTop="51dp"
|
||||
android:background="@drawable/blue_roundend_rectangle"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/text_action_point">
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/left_ring_with_text_container"
|
||||
android:layout_width="33dp"
|
||||
android:layout_height="33dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/left_ring"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:src="@drawable/ring_has_bg"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/left_ring_text"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="2"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="19sp"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/left_ring"
|
||||
app:layout_constraintEnd_toEndOf="@+id/left_ring"
|
||||
app:layout_constraintStart_toStartOf="@+id/left_ring"
|
||||
app:layout_constraintTop_toTopOf="@+id/left_ring" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/right_arrow_from_left_ring"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="8dp"
|
||||
android:src="@drawable/white_arrow_right"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/left_ring_with_text_container"
|
||||
app:layout_constraintStart_toEndOf="@+id/left_ring_with_text_container"
|
||||
app:layout_constraintTop_toTopOf="@+id/left_ring_with_text_container" />
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/right_ring_with_text_container"
|
||||
android:layout_width="33dp"
|
||||
android:layout_height="33dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/right_ring"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:src="@drawable/ring_has_bg"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/right_ring_text"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="2"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="19sp"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/right_ring"
|
||||
app:layout_constraintEnd_toEndOf="@+id/right_ring"
|
||||
app:layout_constraintStart_toStartOf="@+id/right_ring"
|
||||
app:layout_constraintTop_toTopOf="@+id/right_ring" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/left_arrow_to_right_ring"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:src="@drawable/white_arrow_right"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/right_ring_with_text_container"
|
||||
app:layout_constraintEnd_toStartOf="@+id/right_ring_with_text_container"
|
||||
app:layout_constraintTop_toTopOf="@+id/right_ring_with_text_container" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text_swipe_point"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="25dp"
|
||||
android:text="Drag the start/end point of swipe route to move
|
||||
\nit anywhere, click on either of the two to edit the
|
||||
\ninterval or duration"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintEnd_toEndOf="@+id/blue_rounded_rectangle"
|
||||
app:layout_constraintStart_toStartOf="@+id/blue_rounded_rectangle"
|
||||
app:layout_constraintTop_toBottomOf="@+id/blue_rounded_rectangle" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
</androidx.core.widget.NestedScrollView>
|
||||
221
app/src/main/res/layout/fragment_how_single.xml
Normal file
221
app/src/main/res/layout/fragment_how_single.xml
Normal file
@ -0,0 +1,221 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/left_control_bar"
|
||||
android:layout_width="34dp"
|
||||
android:layout_height="149dp"
|
||||
android:layout_marginStart="24dp"
|
||||
android:layout_marginTop="98dp"
|
||||
android:src="@mipmap/single_control_bar"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text_play_stop"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="40dp"
|
||||
android:layout_marginTop="10dp"
|
||||
android:text="Play/Stop"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toEndOf="@+id/left_control_bar"
|
||||
app:layout_constraintTop_toTopOf="@+id/left_control_bar" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/dash_line_1"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="1dp"
|
||||
android:layout_marginEnd="6dp"
|
||||
android:src="@mipmap/line_1"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/text_play_stop"
|
||||
app:layout_constraintEnd_toStartOf="@+id/text_play_stop"
|
||||
app:layout_constraintStart_toEndOf="@+id/left_control_bar"
|
||||
app:layout_constraintTop_toTopOf="@+id/text_play_stop" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text_save_load"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="11dp"
|
||||
android:text="Save/Load scripts"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toStartOf="@+id/text_play_stop"
|
||||
app:layout_constraintTop_toBottomOf="@+id/text_play_stop" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/dash_line_2"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="1dp"
|
||||
android:layout_marginEnd="6dp"
|
||||
android:src="@mipmap/line_1"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/text_save_load"
|
||||
app:layout_constraintEnd_toStartOf="@+id/text_save_load"
|
||||
app:layout_constraintStart_toEndOf="@+id/left_control_bar"
|
||||
app:layout_constraintTop_toTopOf="@+id/text_save_load" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text_hide_unhide"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:text="Hide/Unhide"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toStartOf="@+id/text_play_stop"
|
||||
app:layout_constraintTop_toBottomOf="@+id/text_save_load" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/dash_line_3"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="1dp"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:src="@mipmap/line_1"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/text_hide_unhide"
|
||||
app:layout_constraintEnd_toStartOf="@+id/text_hide_unhide"
|
||||
app:layout_constraintStart_toEndOf="@+id/left_control_bar"
|
||||
app:layout_constraintTop_toTopOf="@+id/text_hide_unhide" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text_edit_repeat_mode"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="9dp"
|
||||
android:text="Edit repeat mode"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toStartOf="@+id/text_play_stop"
|
||||
app:layout_constraintTop_toBottomOf="@+id/text_hide_unhide" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/dash_line_4"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="1dp"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:src="@mipmap/line_1"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/text_edit_repeat_mode"
|
||||
app:layout_constraintEnd_toStartOf="@+id/text_edit_repeat_mode"
|
||||
app:layout_constraintStart_toEndOf="@+id/left_control_bar"
|
||||
app:layout_constraintTop_toTopOf="@+id/text_edit_repeat_mode" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text_stop_service"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="6dp"
|
||||
android:text="Stop service"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toStartOf="@+id/text_play_stop"
|
||||
app:layout_constraintTop_toBottomOf="@+id/text_edit_repeat_mode" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/dash_line_5"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="1dp"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:src="@mipmap/line_1"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/text_stop_service"
|
||||
app:layout_constraintEnd_toStartOf="@+id/text_stop_service"
|
||||
app:layout_constraintStart_toEndOf="@+id/left_control_bar"
|
||||
app:layout_constraintTop_toTopOf="@+id/text_stop_service" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text_move_point"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="26dp"
|
||||
android:text="Drag the bar to move it anywhere"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toStartOf="@+id/text_play_stop"
|
||||
app:layout_constraintTop_toBottomOf="@+id/text_stop_service" />
|
||||
|
||||
<View
|
||||
android:id="@+id/left_bar_center_point_x"
|
||||
android:layout_width="1dp"
|
||||
android:layout_height="0dp"
|
||||
android:visibility="gone"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/left_control_bar"
|
||||
app:layout_constraintEnd_toEndOf="@+id/left_control_bar"
|
||||
app:layout_constraintStart_toStartOf="@+id/left_control_bar" />
|
||||
|
||||
<View
|
||||
android:id="@+id/text_point_center_point_y"
|
||||
android:layout_width="1dp"
|
||||
android:layout_height="0dp"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/text_move_point"
|
||||
app:layout_constraintEnd_toEndOf="@+id/text_move_point"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toStartOf="@+id/text_move_point"
|
||||
app:layout_constraintTop_toTopOf="@+id/text_move_point"
|
||||
app:layout_constraintVertical_bias="0.5" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/dash_line_6"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="8dp"
|
||||
android:src="@mipmap/line_2"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/text_point_center_point_y"
|
||||
app:layout_constraintEnd_toStartOf="@+id/text_move_point"
|
||||
app:layout_constraintStart_toStartOf="@+id/left_bar_center_point_x"
|
||||
app:layout_constraintTop_toBottomOf="@+id/left_control_bar" />
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/ring_with_text_container"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="19dp"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/text_action_point"
|
||||
app:layout_constraintEnd_toStartOf="@+id/text_action_point"
|
||||
app:layout_constraintTop_toTopOf="@+id/text_action_point">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ring"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/ring_has_bg"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/ring_text"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="1"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="26sp"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/ring"
|
||||
app:layout_constraintEnd_toEndOf="@+id/ring"
|
||||
app:layout_constraintStart_toStartOf="@+id/ring"
|
||||
app:layout_constraintTop_toTopOf="@+id/ring" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text_action_point"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="87dp"
|
||||
android:text="Drag the action point to move
|
||||
\nit anywhere, click to edit the"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="14sp"
|
||||
app:layout_constraintStart_toStartOf="@+id/text_play_stop"
|
||||
app:layout_constraintTop_toBottomOf="@+id/text_move_point" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
146
app/src/main/res/layout/fragment_u_i_size.xml
Normal file
146
app/src/main/res/layout/fragment_u_i_size.xml
Normal file
@ -0,0 +1,146 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.core.widget.NestedScrollView xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
tools:context=".ui.fragment.setting.UISizeFragment">
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingBottom="25dp">
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/point_size_container"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="180dp"
|
||||
android:layout_marginStart="20dp"
|
||||
android:layout_marginTop="14dp"
|
||||
android:layout_marginEnd="20dp"
|
||||
android:background="@drawable/bg_rounded_rect"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/pint_size_title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="19dp"
|
||||
android:layout_marginTop="7dp"
|
||||
android:text="Action Point Size"
|
||||
android:textColor="@color/text_gray"
|
||||
android:textSize="15sp"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<SeekBar
|
||||
android:id="@+id/point_seekbar"
|
||||
style="?android:attr/progressBarStyleHorizontal"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_marginStart="14dp"
|
||||
android:layout_marginEnd="11dp"
|
||||
android:layout_marginTop="29dp"
|
||||
android:max="100"
|
||||
android:maxHeight="5dp"
|
||||
android:progress="0"
|
||||
app:layout_constraintTop_toBottomOf="@+id/pint_size_title"
|
||||
android:progressDrawable="@drawable/seek_bar_color_white"
|
||||
android:thumb="@drawable/seekbar_thumb_white" />
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/ring_with_text_container"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="27dp"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/point_seekbar">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ring"
|
||||
android:layout_width="33dp"
|
||||
android:layout_height="33dp"
|
||||
android:src="@drawable/ring_has_bg"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/ring_text"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="P"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="19sp"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/ring"
|
||||
app:layout_constraintEnd_toEndOf="@+id/ring"
|
||||
app:layout_constraintStart_toStartOf="@+id/ring"
|
||||
app:layout_constraintTop_toTopOf="@+id/ring" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/bar_size_container"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="419dp"
|
||||
android:layout_marginStart="20dp"
|
||||
android:layout_marginTop="22dp"
|
||||
android:layout_marginEnd="20dp"
|
||||
android:background="@drawable/bg_rounded_rect"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/point_size_container">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/bar_size_title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="19dp"
|
||||
android:layout_marginTop="7dp"
|
||||
android:text="Control Bar Size"
|
||||
android:textColor="@color/text_gray"
|
||||
android:textSize="15sp"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<SeekBar
|
||||
android:id="@+id/bar_seekbar"
|
||||
style="?android:attr/progressBarStyleHorizontal"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_marginStart="14dp"
|
||||
android:layout_marginEnd="11dp"
|
||||
android:layout_marginTop="29dp"
|
||||
android:max="100"
|
||||
android:maxHeight="5dp"
|
||||
android:progress="0"
|
||||
app:layout_constraintTop_toBottomOf="@+id/bar_size_title"
|
||||
android:progressDrawable="@drawable/seek_bar_color_white"
|
||||
android:thumb="@drawable/seekbar_thumb_white" />
|
||||
|
||||
<ImageView
|
||||
android:layout_width="37dp"
|
||||
android:layout_height="249dp"
|
||||
android:id="@+id/control_bar"
|
||||
android:src="@mipmap/multi_control_bar"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/bar_seekbar"
|
||||
android:layout_marginTop="50dp" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
</androidx.core.widget.NestedScrollView>
|
||||
23
app/src/main/res/layout/how_tab.xml
Normal file
23
app/src/main/res/layout/how_tab.xml
Normal file
@ -0,0 +1,23 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingStart="16dp"
|
||||
android:paddingEnd="16dp"
|
||||
android:paddingTop="8dp"
|
||||
android:paddingBottom="8dp">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/text_custom"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:textColor="@color/tab_text_color_selector"
|
||||
android:textSize="16sp"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@ -1,10 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
android:padding="12dp"
|
||||
android:id="@+id/item_menu"
|
||||
android:background="?attr/selectableItemBackground"
|
||||
android:gravity="center_vertical"
|
||||
android:layout_marginBottom="8dp">
|
||||
|
||||
89
app/src/main/res/layout/multiple_control_bar.xml
Normal file
89
app/src/main/res/layout/multiple_control_bar.xml
Normal file
@ -0,0 +1,89 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="38dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@drawable/control_bar_bg"
|
||||
android:orientation="vertical">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center_horizontal"
|
||||
android:orientation="vertical"
|
||||
android:paddingHorizontal="10dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/play_button"
|
||||
android:layout_width="13dp"
|
||||
android:layout_height="13dp"
|
||||
android:layout_marginTop="15dp"
|
||||
android:layout_marginBottom="16dp"
|
||||
android:src="@drawable/play" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/add_button"
|
||||
android:layout_width="13dp"
|
||||
android:layout_height="13dp"
|
||||
android:layout_marginBottom="16dp"
|
||||
android:src="@drawable/add" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/remove_button"
|
||||
android:layout_width="13dp"
|
||||
android:layout_height="2dp"
|
||||
android:layout_marginBottom="16dp"
|
||||
android:src="@drawable/remove" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/slide_button"
|
||||
android:layout_width="17dp"
|
||||
android:layout_height="17dp"
|
||||
android:layout_marginBottom="16dp"
|
||||
android:src="@drawable/slide" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/save_button"
|
||||
android:layout_width="15dp"
|
||||
android:layout_height="15dp"
|
||||
android:layout_marginBottom="16dp"
|
||||
android:src="@drawable/save" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/eye_button"
|
||||
android:layout_width="16dp"
|
||||
android:layout_height="9dp"
|
||||
android:layout_marginBottom="16dp"
|
||||
android:src="@drawable/eye" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/settings_button"
|
||||
android:layout_width="14dp"
|
||||
android:layout_height="14dp"
|
||||
android:layout_marginBottom="9dp"
|
||||
android:src="@drawable/control_setting" />
|
||||
</LinearLayout>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/cut_off"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="1dp"
|
||||
android:layout_marginBottom="10dp"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/cut_off_line" />
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center_horizontal"
|
||||
android:orientation="vertical"
|
||||
android:paddingHorizontal="10dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/close_button"
|
||||
android:layout_width="10dp"
|
||||
android:layout_height="10dp"
|
||||
android:layout_marginBottom="11dp"
|
||||
android:src="@drawable/cancel" />
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
BIN
app/src/main/res/mipmap-hdpi/line_1.png
Normal file
BIN
app/src/main/res/mipmap-hdpi/line_1.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 352 B |
BIN
app/src/main/res/mipmap-hdpi/line_2.png
Normal file
BIN
app/src/main/res/mipmap-hdpi/line_2.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.0 KiB |
BIN
app/src/main/res/mipmap-hdpi/multi_control_bar.png
Normal file
BIN
app/src/main/res/mipmap-hdpi/multi_control_bar.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 11 KiB |
BIN
app/src/main/res/mipmap-hdpi/single_control_bar.png
Normal file
BIN
app/src/main/res/mipmap-hdpi/single_control_bar.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 7.8 KiB |
BIN
app/src/main/res/raw/bolangblue.mp4
Normal file
BIN
app/src/main/res/raw/bolangblue.mp4
Normal file
Binary file not shown.
BIN
app/src/main/res/raw/bolangred.mp4
Normal file
BIN
app/src/main/res/raw/bolangred.mp4
Normal file
Binary file not shown.
@ -4,4 +4,7 @@
|
||||
<color name="white">#FFFFFFFF</color>
|
||||
<color name="blue">#0BC4FC</color>
|
||||
<color name="gray">#616161</color>
|
||||
<color name="bg_blue">#113945</color>
|
||||
<color name="text_gray">#8DA5A7</color>
|
||||
<color name="button_gray">#446672</color>
|
||||
</resources>
|
||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user