Upload Code

This commit is contained in:
mxdabc
2026-04-13 23:56:09 +08:00
parent 6c3c7de263
commit 58fc5cf7a3
33 changed files with 891 additions and 0 deletions

View File

@@ -1,2 +1,3 @@
# Tools # Tools
Draft.

36
app/build.gradle Normal file
View File

@@ -0,0 +1,36 @@
plugins {
id 'com.android.application'
}
android {
namespace 'com.mxdyeah.tools'
compileSdk 31
defaultConfig {
applicationId "com.mxdyeah.tools"
minSdk 21
targetSdk 31
versionCode 1
versionName "1.0"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
}
dependencies {
implementation 'androidx.appcompat:appcompat:1.3.1'
implementation 'com.google.android.material:material:1.4.0'
implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
implementation 'com.journeyapps:zxing-android-embedded:4.3.0'
implementation 'com.google.zxing:core:3.5.3'
implementation 'com.google.android.gms:play-services-ads:20.6.0'
}

2
app/proguard-rules.pro vendored Normal file
View File

@@ -0,0 +1,2 @@
-keep class com.google.android.gms.** { *; }
-keep class com.google.ads.** { *; }

View File

@@ -0,0 +1,58 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools">
<uses-permission android:name="android.permission.CAMERA" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-feature android:name="android.hardware.camera" android:required="false" />
<application
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="@style/Theme.Tools"
tools:targetApi="q">
<meta-data
android:name="com.google.android.gms.ads.APPLICATION_ID"
android:value="ca-app-pub-7916126561134304~4909469521"/>
<activity
android:name=".MainActivity"
android:exported="true"
android:theme="@style/Theme.Tools">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name=".GenerateActivity"
android:exported="false"
android:parentActivityName=".MainActivity" />
<activity
android:name=".ScanActivity"
android:exported="false"
android:parentActivityName=".MainActivity" />
<activity
android:name=".AdActivity"
android:exported="true"
android:theme="@style/Theme.Tools">
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data android:scheme="https" />
</intent-filter>
</activity>
</application>
</manifest>

View File

@@ -0,0 +1,85 @@
package com.mxdyeah.tools;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.webkit.WebView;
import android.webkit.WebViewClient;
import android.widget.FrameLayout;
import android.widget.ProgressBar;
import androidx.appcompat.app.AppCompatActivity;
import com.google.android.gms.ads.AdRequest;
import com.google.android.gms.ads.AdSize;
import com.google.android.gms.ads.AdView;
import com.google.android.gms.ads.MobileAds;
import com.google.android.gms.ads.initialization.InitializationStatus;
import com.google.android.gms.ads.initialization.OnInitializationCompleteListener;
import com.google.android.gms.ads.AdListener;
import com.google.android.gms.ads.LoadAdError;
public class AdActivity extends AppCompatActivity {
private WebView webView;
private ProgressBar progressBar;
private AdView adView;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_ad);
MobileAds.initialize(this, new OnInitializationCompleteListener() {
@Override
public void onInitializationComplete(InitializationStatus status) {
Log.d("AdActivity", "Mobile Ads initialized");
}
});
webView = findViewById(R.id.webView);
progressBar = findViewById(R.id.progressBar);
webView.setWebViewClient(new WebViewClient() {
@Override
public void onPageFinished(WebView view, String url) {
progressBar.setVisibility(View.GONE);
}
});
webView.getSettings().setJavaScriptEnabled(true);
webView.loadUrl("https://www.mxdyeah.com");
FrameLayout adContainer = findViewById(R.id.adContainer);
adView = new AdView(this);
//adView.setAdUnitId("ca-app-pub-7916126561134304/3815879702");
//use google admob test id
adView.setAdUnitId("ca-app-pub-3940256099942544/6300978111");
adView.setAdSize(AdSize.BANNER);
adContainer.addView(adView);
AdRequest adRequest = new AdRequest.Builder().build();
adView.loadAd(adRequest);
adView.setAdListener(new AdListener() {
@Override
public void onAdLoaded() {
Log.d("AdMob", "Ad loaded");
}
@Override
public void onAdFailedToLoad(LoadAdError error) {
Log.e("AdMob", "Failed code: " + error.getCode());
Log.e("AdMob", "Failed message: " + error.getMessage());
Log.e("AdMob", "Full: " + error.toString());
}
});
}
@Override
protected void onDestroy() {
if (adView != null) {
adView.destroy();
}
super.onDestroy();
}
}

View File

@@ -0,0 +1,73 @@
package com.mxdyeah.tools;
import android.graphics.Bitmap;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;
import android.widget.EditText;
import android.widget.ImageView;
import android.widget.Toast;
import androidx.appcompat.app.AppCompatActivity;
import com.google.zxing.BarcodeFormat;
import com.google.zxing.EncodeHintType;
import com.google.zxing.qrcode.QRCodeWriter;
import com.google.zxing.common.BitMatrix;
import java.util.Hashtable;
public class GenerateActivity extends AppCompatActivity {
private EditText etContent;
private ImageView ivQRCode;
private Button btnGenerate;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_generate);
etContent = findViewById(R.id.etContent);
ivQRCode = findViewById(R.id.ivQRCode);
btnGenerate = findViewById(R.id.btnGenerate);
btnGenerate.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
String content = etContent.getText().toString().trim();
if (content.isEmpty()) {
Toast.makeText(GenerateActivity.this, "请输入内容", Toast.LENGTH_SHORT).show();
return;
}
generateQRCode(content);
}
});
}
private void generateQRCode(String content) {
try {
Hashtable<EncodeHintType, String> hints = new Hashtable<>();
hints.put(EncodeHintType.CHARACTER_SET, "UTF-8");
QRCodeWriter writer = new QRCodeWriter();
BitMatrix bitMatrix = writer.encode(content, BarcodeFormat.QR_CODE, 512, 512, hints);
int width = bitMatrix.getWidth();
int height = bitMatrix.getHeight();
int[] pixels = new int[width * height];
for (int y = 0; y < height; y++) {
int offset = y * width;
for (int x = 0; x < width; x++) {
pixels[offset + x] = bitMatrix.get(x, y) ? 0xFF000000 : 0xFFFFFFFF;
}
}
Bitmap bitmap = Bitmap.createBitmap(width, height, Bitmap.Config.ARGB_8888);
bitmap.setPixels(pixels, 0, width, 0, 0, width, height);
ivQRCode.setImageBitmap(bitmap);
} catch (Exception e) {
e.printStackTrace();
Toast.makeText(this, "生成失败: " + e.getMessage(), Toast.LENGTH_SHORT).show();
}
}
}

View File

@@ -0,0 +1,61 @@
package com.mxdyeah.tools;
import android.content.Intent;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.widget.Button;
import androidx.appcompat.app.AppCompatActivity;
import com.google.android.gms.ads.MobileAds;
import com.google.android.gms.ads.AdRequest;
import com.google.android.gms.ads.AdView;
import com.google.android.gms.ads.initialization.InitializationStatus;
import com.google.android.gms.ads.initialization.OnInitializationCompleteListener;
public class MainActivity extends AppCompatActivity {
private AdView mAdView;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
MobileAds.initialize(this, new OnInitializationCompleteListener() {
@Override
public void onInitializationComplete(InitializationStatus status) {
Log.d("MainActivity", "Mobile Ads initialized");
}
});
mAdView = findViewById(R.id.adView);
AdRequest adRequest = new AdRequest.Builder().build();
mAdView.loadAd(adRequest);
Button btnGenerate = findViewById(R.id.btnGenerate);
Button btnScan = findViewById(R.id.btnScan);
Button btnAd = findViewById(R.id.btnAd);
btnGenerate.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
startActivity(new Intent(MainActivity.this, GenerateActivity.class));
}
});
btnScan.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
startActivity(new Intent(MainActivity.this, ScanActivity.class));
}
});
btnAd.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
startActivity(new Intent(MainActivity.this, AdActivity.class));
}
});
}
}

View File

@@ -0,0 +1,66 @@
package com.mxdyeah.tools;
import android.Manifest;
import android.content.Intent;
import android.content.pm.PackageManager;
import android.os.Bundle;
import android.widget.Toast;
import androidx.annotation.NonNull;
import androidx.appcompat.app.AppCompatActivity;
import androidx.core.app.ActivityCompat;
import androidx.core.content.ContextCompat;
import com.google.zxing.integration.android.IntentIntegrator;
import com.google.zxing.integration.android.IntentResult;
public class ScanActivity extends AppCompatActivity {
private static final int REQUEST_CAMERA_PERMISSION = 100;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
if (ContextCompat.checkSelfPermission(this, Manifest.permission.CAMERA) != PackageManager.PERMISSION_GRANTED) {
ActivityCompat.requestPermissions(this, new String[]{Manifest.permission.CAMERA}, REQUEST_CAMERA_PERMISSION);
} else {
startScan();
}
}
@Override
public void onRequestPermissionsResult(int requestCode, @NonNull String[] permissions, @NonNull int[] grantResults) {
super.onRequestPermissionsResult(requestCode, permissions, grantResults);
if (requestCode == REQUEST_CAMERA_PERMISSION) {
if (grantResults.length > 0 && grantResults[0] == PackageManager.PERMISSION_GRANTED) {
startScan();
} else {
Toast.makeText(this, "需要相机权限才能扫描", Toast.LENGTH_SHORT).show();
finish();
}
}
}
private void startScan() {
IntentIntegrator integrator = new IntentIntegrator(this);
integrator.setDesiredBarcodeFormats(IntentIntegrator.QR_CODE);
integrator.setPrompt("扫描二维码");
integrator.setCameraId(0);
integrator.setBeepEnabled(true);
integrator.setBarcodeImageEnabled(true);
integrator.initiateScan();
}
@Override
protected void onActivityResult(int requestCode, int resultCode, Intent data) {
IntentResult result = IntentIntegrator.parseActivityResult(requestCode, resultCode, data);
if (result != null) {
if (result.getContents() != null) {
Toast.makeText(this, "扫描结果: " + result.getContents(), Toast.LENGTH_LONG).show();
} else {
Toast.makeText(this, "取消扫描", Toast.LENGTH_SHORT).show();
}
}
super.onActivityResult(requestCode, resultCode, data);
finish();
}
}

View File

@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="108dp"
android:height="108dp"
android:viewportWidth="108"
android:viewportHeight="108">
<path
android:fillColor="#6200EE"
android:pathData="M0,0h108v108h-108z"/>
</vector>

View File

@@ -0,0 +1,24 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<FrameLayout
android:id="@+id/adContainer"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="#FFFFFF"/>
<ProgressBar
android:id="@+id/progressBar"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"/>
<WebView
android:id="@+id/webView"
android:layout_width="match_parent"
android:layout_height="match_parent"/>
</LinearLayout>

View File

@@ -0,0 +1,31 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:padding="16dp">
<EditText
android:id="@+id/etContent"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="请输入内容"
android:inputType="text"
android:padding="12dp"/>
<Button
android:id="@+id/btnGenerate"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="生成二维码"
android:layout_marginTop="16dp"/>
<ImageView
android:id="@+id/ivQRCode"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1"
android:scaleType="fitCenter"
android:layout_marginTop="16dp"/>
</LinearLayout>

View File

@@ -0,0 +1,52 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:gravity="center"
android:padding="24dp">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="二维码工具"
android:textSize="28sp"
android:textStyle="bold"
android:layout_marginBottom="32dp"/>
<Button
android:id="@+id/btnGenerate"
android:layout_width="200dp"
android:layout_height="60dp"
android:text="生成二维码"
android:textSize="18sp"
android:layout_marginBottom="16dp"/>
<Button
android:id="@+id/btnScan"
android:layout_width="200dp"
android:layout_height="60dp"
android:text="扫描二维码"
android:textSize="18sp"
android:layout_marginBottom="16dp"/>
<Button
android:id="@+id/btnAd"
android:layout_width="200dp"
android:layout_height="60dp"
android:text="广告页面"
android:textSize="18sp"
android:layout_marginBottom="24dp"/>
<com.google.android.gms.ads.AdView
xmlns:ads="http://schemas.android.com/apk/res-auto"
android:id="@+id/adView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerHorizontal="true"
android:layout_alignParentBottom="true"
ads:adSize="BANNER"
ads:adUnitId="ca-app-pub-7916126561134304/3815879702">
</com.google.android.gms.ads.AdView>
</LinearLayout>

View File

@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@color/purple_500"/>
<foreground android:drawable="@mipmap/ic_launcher_foreground"/>
</adaptive-icon>

View File

@@ -0,0 +1,28 @@
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="108dp"
android:height="108dp"
android:viewportWidth="108"
android:viewportHeight="108">
<path
android:fillColor="#FFFFFF"
android:pathData="M54,54m-30,0a30,30 0,1 1,60 0a30,30 0,1 1,-60 0"/>
<path
android:fillColor="#6200EE"
android:pathData="M44,44h20v20h-20z"/>
<path
android:fillColor="#6200EE"
android:pathData="M46,46h4v4h-4z"/>
<path
android:fillColor="#6200EE"
android:pathData="M58,46h4v4h-4z"/>
<path
android:fillColor="#6200EE"
android:pathData="M46,58h4v4h-4z"/>
<path
android:fillColor="#6200EE"
android:pathData="M52,52h4v4h-4z"/>
<path
android:fillColor="#6200EE"
android:pathData="M58,58h4v4h-4z"/>
</vector>

View File

@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@color/purple_500"/>
<foreground android:drawable="@mipmap/ic_launcher_foreground"/>
</adaptive-icon>

View File

@@ -0,0 +1,28 @@
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="48dp"
android:height="48dp"
android:viewportWidth="48"
android:viewportHeight="48">
<path
android:fillColor="#6200EE"
android:pathData="M0,0h48v48h-48z"/>
<path
android:fillColor="#FFFFFF"
android:pathData="M14,14h20v20h-20z"/>
<path
android:fillColor="#6200EE"
android:pathData="M16,16h4v4h-4z"/>
<path
android:fillColor="#6200EE"
android:pathData="M28,16h4v4h-4z"/>
<path
android:fillColor="#6200EE"
android:pathData="M16,28h4v4h-4z"/>
<path
android:fillColor="#6200EE"
android:pathData="M22,22h4v4h-4z"/>
<path
android:fillColor="#6200EE"
android:pathData="M28,28h4v4h-4z"/>
</vector>

View File

@@ -0,0 +1,28 @@
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="48dp"
android:height="48dp"
android:viewportWidth="48"
android:viewportHeight="48">
<path
android:fillColor="#6200EE"
android:pathData="M0,0h48v48h-48z"/>
<path
android:fillColor="#FFFFFF"
android:pathData="M14,14h20v20h-20z"/>
<path
android:fillColor="#6200EE"
android:pathData="M16,16h4v4h-4z"/>
<path
android:fillColor="#6200EE"
android:pathData="M28,16h4v4h-4z"/>
<path
android:fillColor="#6200EE"
android:pathData="M16,28h4v4h-4z"/>
<path
android:fillColor="#6200EE"
android:pathData="M22,22h4v4h-4z"/>
<path
android:fillColor="#6200EE"
android:pathData="M28,28h4v4h-4z"/>
</vector>

View File

@@ -0,0 +1,28 @@
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="72dp"
android:height="72dp"
android:viewportWidth="72"
android:viewportHeight="72">
<path
android:fillColor="#6200EE"
android:pathData="M0,0h72v72h-72z"/>
<path
android:fillColor="#FFFFFF"
android:pathData="M21,21h30v30h-30z"/>
<path
android:fillColor="#6200EE"
android:pathData="M24,24h6v6h-6z"/>
<path
android:fillColor="#6200EE"
android:pathData="M42,24h6v6h-6z"/>
<path
android:fillColor="#6200EE"
android:pathData="M24,42h6v6h-6z"/>
<path
android:fillColor="#6200EE"
android:pathData="M33,33h6v6h-6z"/>
<path
android:fillColor="#6200EE"
android:pathData="M42,42h6v6h-6z"/>
</vector>

View File

@@ -0,0 +1,28 @@
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="72dp"
android:height="72dp"
android:viewportWidth="72"
android:viewportHeight="72">
<path
android:fillColor="#6200EE"
android:pathData="M0,0h72v72h-72z"/>
<path
android:fillColor="#FFFFFF"
android:pathData="M21,21h30v30h-30z"/>
<path
android:fillColor="#6200EE"
android:pathData="M24,24h6v6h-6z"/>
<path
android:fillColor="#6200EE"
android:pathData="M42,24h6v6h-6z"/>
<path
android:fillColor="#6200EE"
android:pathData="M24,42h6v6h-6z"/>
<path
android:fillColor="#6200EE"
android:pathData="M33,33h6v6h-6z"/>
<path
android:fillColor="#6200EE"
android:pathData="M42,42h6v6h-6z"/>
</vector>

View File

@@ -0,0 +1,28 @@
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="96dp"
android:height="96dp"
android:viewportWidth="96"
android:viewportHeight="96">
<path
android:fillColor="#6200EE"
android:pathData="M0,0h96v96h-96z"/>
<path
android:fillColor="#FFFFFF"
android:pathData="M28,28h40v40h-40z"/>
<path
android:fillColor="#6200EE"
android:pathData="M32,32h8v8h-8z"/>
<path
android:fillColor="#6200EE"
android:pathData="M56,32h8v8h-8z"/>
<path
android:fillColor="#6200EE"
android:pathData="M32,56h8v8h-8z"/>
<path
android:fillColor="#6200EE"
android:pathData="M44,44h8v8h-8z"/>
<path
android:fillColor="#6200EE"
android:pathData="M56,56h8v8h-8z"/>
</vector>

View File

@@ -0,0 +1,28 @@
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="96dp"
android:height="96dp"
android:viewportWidth="96"
android:viewportHeight="96">
<path
android:fillColor="#6200EE"
android:pathData="M0,0h96v96h-96z"/>
<path
android:fillColor="#FFFFFF"
android:pathData="M28,28h40v40h-40z"/>
<path
android:fillColor="#6200EE"
android:pathData="M32,32h8v8h-8z"/>
<path
android:fillColor="#6200EE"
android:pathData="M56,32h8v8h-8z"/>
<path
android:fillColor="#6200EE"
android:pathData="M32,56h8v8h-8z"/>
<path
android:fillColor="#6200EE"
android:pathData="M44,44h8v8h-8z"/>
<path
android:fillColor="#6200EE"
android:pathData="M56,56h8v8h-8z"/>
</vector>

View File

@@ -0,0 +1,28 @@
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="144dp"
android:height="144dp"
android:viewportWidth="144"
android:viewportHeight="144">
<path
android:fillColor="#6200EE"
android:pathData="M0,0h144v144h-144z"/>
<path
android:fillColor="#FFFFFF"
android:pathData="M42,42h60v60h-60z"/>
<path
android:fillColor="#6200EE"
android:pathData="M48,48h12v12h-12z"/>
<path
android:fillColor="#6200EE"
android:pathData="M84,48h12v12h-12z"/>
<path
android:fillColor="#6200EE"
android:pathData="M48,84h12v12h-12z"/>
<path
android:fillColor="#6200EE"
android:pathData="M66,66h12v12h-12z"/>
<path
android:fillColor="#6200EE"
android:pathData="M84,84h12v12h-12z"/>
</vector>

View File

@@ -0,0 +1,28 @@
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="144dp"
android:height="144dp"
android:viewportWidth="144"
android:viewportHeight="144">
<path
android:fillColor="#6200EE"
android:pathData="M0,0h144v144h-144z"/>
<path
android:fillColor="#FFFFFF"
android:pathData="M42,42h60v60h-60z"/>
<path
android:fillColor="#6200EE"
android:pathData="M48,48h12v12h-12z"/>
<path
android:fillColor="#6200EE"
android:pathData="M84,48h12v12h-12z"/>
<path
android:fillColor="#6200EE"
android:pathData="M48,84h12v12h-12z"/>
<path
android:fillColor="#6200EE"
android:pathData="M66,66h12v12h-12z"/>
<path
android:fillColor="#6200EE"
android:pathData="M84,84h12v12h-12z"/>
</vector>

View File

@@ -0,0 +1,28 @@
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="192dp"
android:height="192dp"
android:viewportWidth="192"
android:viewportHeight="192">
<path
android:fillColor="#6200EE"
android:pathData="M0,0h192v192h-192z"/>
<path
android:fillColor="#FFFFFF"
android:pathData="M56,56h80v80h-80z"/>
<path
android:fillColor="#6200EE"
android:pathData="M64,64h16v16h-16z"/>
<path
android:fillColor="#6200EE"
android:pathData="M112,64h16v16h-16z"/>
<path
android:fillColor="#6200EE"
android:pathData="M64,112h16v16h-16z"/>
<path
android:fillColor="#6200EE"
android:pathData="M88,88h16v16h-16z"/>
<path
android:fillColor="#6200EE"
android:pathData="M112,112h16v16h-16z"/>
</vector>

View File

@@ -0,0 +1,28 @@
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="192dp"
android:height="192dp"
android:viewportWidth="192"
android:viewportHeight="192">
<path
android:fillColor="#6200EE"
android:pathData="M0,0h192v192h-192z"/>
<path
android:fillColor="#FFFFFF"
android:pathData="M56,56h80v80h-80z"/>
<path
android:fillColor="#6200EE"
android:pathData="M64,64h16v16h-16z"/>
<path
android:fillColor="#6200EE"
android:pathData="M112,64h16v16h-16z"/>
<path
android:fillColor="#6200EE"
android:pathData="M64,112h16v16h-16z"/>
<path
android:fillColor="#6200EE"
android:pathData="M88,88h16v16h-16z"/>
<path
android:fillColor="#6200EE"
android:pathData="M112,112h16v16h-16z"/>
</vector>

View File

@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="purple_200">#FFBB86FC</color>
<color name="purple_500">#FF6200EE</color>
<color name="purple_700">#FF3700B3</color>
<color name="teal_200">#FF03DAC5</color>
<color name="teal_700">#FF018786</color>
<color name="black">#FF000000</color>
<color name="white">#FFFFFFFF</color>
</resources>

View File

@@ -0,0 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="app_name">Tools</string>
</resources>

View File

@@ -0,0 +1,12 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<style name="Theme.Tools" parent="Theme.MaterialComponents.DayNight.DarkActionBar">
<item name="colorPrimary">@color/purple_500</item>
<item name="colorPrimaryVariant">@color/purple_700</item>
<item name="colorOnPrimary">@color/white</item>
<item name="colorSecondary">@color/teal_200</item>
<item name="colorSecondaryVariant">@color/teal_700</item>
<item name="colorOnSecondary">@color/black</item>
<item name="android:statusBarColor">?attr/colorPrimaryVariant</item>
</style>
</resources>

3
build.gradle Normal file
View File

@@ -0,0 +1,3 @@
plugins {
id 'com.android.application' version '7.0.2' apply false
}

4
gradle.properties Normal file
View File

@@ -0,0 +1,4 @@
org.gradle.jvmargs=-Xmx2048m -Dfile.encoding=UTF-8
android.useAndroidX=true
android.nonTransitiveRClass=true
org.gradle.jvmargs=-Dfile.encoding=UTF-8

View File

@@ -0,0 +1,6 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
#distributionUrl=https\://services.gradle.org/distributions/gradle-8.0-bin.zip
distributionUrl=https\://mirrors.aliyun.com/gradle/distributions/v7.0.2/gradle-7.0.2-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists

8
local.properties Normal file
View File

@@ -0,0 +1,8 @@
## This file must *NOT* be checked into Version Control Systems,
# as it contains information specific to your local configuration.
#
# Location of the SDK. This is only used by Gradle.
# For customization when using a Version Control System, please read the
# header note.
#Sat Apr 11 02:24:43 CST 2026
sdk.dir=F\:\\Android\\AndroidSDK

27
settings.gradle Normal file
View File

@@ -0,0 +1,27 @@
pluginManagement {
repositories {
// 国内镜像(优先)
maven { url 'https://maven.aliyun.com/repository/google' }
maven { url 'https://maven.aliyun.com/repository/public' }
maven { url 'https://maven.aliyun.com/repository/gradle-plugin' }
// 官方源(备用)
google()
mavenCentral()
gradlePluginPortal()
}
}
dependencyResolutionManagement {
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
repositories {
// 国内镜像(优先)
maven { url 'https://maven.aliyun.com/repository/google' }
maven { url 'https://maven.aliyun.com/repository/public' }
// 官方源(备用)
google()
mavenCentral()
}
}
rootProject.name = "Tools"
include ':app'