Skip to content

Commit

Permalink
fix bugs
Browse files Browse the repository at this point in the history
- [FEAT] UI and ICON
- [REV/REF] SSL verify
- [FIX] Bugs
  • Loading branch information
zhwanng committed Oct 29, 2024
1 parent 8c77749 commit ae12e44
Show file tree
Hide file tree
Showing 148 changed files with 6,800 additions and 2,025 deletions.
11 changes: 5 additions & 6 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ android {
targetSdkVersion rootProject.ext.targetSdkVersion
compileSdk rootProject.ext.compileSdkVersion

versionCode 154
versionName "3.0.4"
versionCode 155
versionName "3.0.5"
multiDexEnabled true

resValue "string", "authorities", defaultConfig.applicationId + '.debug.cameraupload.provider'
Expand Down Expand Up @@ -199,14 +199,15 @@ android {
implementation 'androidx.core:core-ktx:1.13.1'
implementation 'androidx.core:core-splashscreen:1.0.1'
implementation "androidx.appcompat:appcompat:1.7.0"
implementation "androidx.activity:activity:1.9.1"
implementation "androidx.activity:activity:1.9.3"
implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
implementation 'androidx.swiperefreshlayout:swiperefreshlayout:1.1.0'
implementation "androidx.preference:preference:1.2.1"
// implementation "androidx.datastore:datastore-preferences:1.0.0"
// implementation "androidx.datastore:datastore-preferences-rxjava2:1.0.0"
implementation "androidx.core:core-splashscreen:1.0.1"
implementation "androidx.webkit:webkit:1.11.0"
implementation "androidx.webkit:webkit:1.12.1"
implementation 'com.google.android.flexbox:flexbox:3.0.0'

//https://github.com/material-components/material-components-android
implementation "com.google.android.material:material:1.12.0"
Expand Down Expand Up @@ -310,8 +311,6 @@ android {
implementation 'com.madgag.spongycastle:core:1.54.0.0'
implementation 'com.madgag.spongycastle:prov:1.54.0.0'

// implementation 'org.greenrobot:eventbus:3.3.1'

def glide_version = "4.16.0"
implementation "com.github.bumptech.glide:glide:$glide_version"
implementation "com.github.bumptech.glide:okhttp3-integration:$glide_version"
Expand Down
2 changes: 2 additions & 0 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -209,6 +209,8 @@
<activity android:name=".ui.BugHandlerActivity" />
<activity android:name=".ui.settings.SettingsAlbumBackupAdvancedActivity" />
<activity android:name=".ui.data_migrate.DataMigrationV303Activity" />
<activity android:name=".ui.sdoc.SDocWebViewActivity" />
<activity android:name=".ui.sdoc.comments.SDocCommentsActivity" />

<provider
android:name=".provider.SeafileProvider"
Expand Down
45 changes: 29 additions & 16 deletions app/src/main/java/com/seafile/seadroid2/account/Account.java
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,14 @@ public Account(String name, String server, String email, String avatar_url, Stri
this.login_time = Long.parseLong(loginTime);
}

public void setServer(String server) {
this.server = server;
}

public void setToken(String token) {
this.token = token;
}

public long getUsageSpace() {
return usage;
}
Expand Down Expand Up @@ -124,20 +132,6 @@ public void setEmail(String email) {
}


public String getServerHost() {
String s = server.substring(server.indexOf("://") + 3);
return s.substring(0, s.indexOf('/'));
}

public String getServerDomainName() {
String dn = getServerHost();
// strip port, like :8000 in 192.168.1.116:8000
if (dn.contains(":"))
dn = dn.substring(0, dn.indexOf(':'));
return dn;
}


public String getEmail() {
return email;
}
Expand All @@ -156,14 +150,33 @@ public String getServer() {
}

/**
* https://dev.xxx.com/dev/ => https://dev.xxx.com
* @return DOMAIN/IP_ADDRESS(:PORT), <br/>like www.goo.gle, like 192.168.0.1:8000
*/
public String getServerHost() {
String s = server.substring(server.indexOf("://") + 3);
return s.substring(0, s.indexOf('/'));
}

/**
* @return DOMAIN/IP_ADDRESS, <br/>like www.goo.gle, like 192.168.0.1
*/
public String getServerDomainName() {
String dn = getServerHost();
// strip port, like :8000 in 192.168.1.116:8000
if (dn.contains(":"))
dn = dn.substring(0, dn.indexOf(':'));
return dn;
}

/**
* @return https://dev.xxx.com/dev/ => https://dev.xxx.com
*/
public String getProtocolHost() {
return URLs.getProtocolHost(server);
}

/**
* https://dev.xxx.com/dev/ => dev.xxx.com/dev
* @return https://dev.xxx.com/dev/ => dev.xxx.com/dev
*/
public String getServerNoProtocol() {
String result = server.substring(server.indexOf("://") + 3);
Expand Down
59 changes: 59 additions & 0 deletions app/src/main/java/com/seafile/seadroid2/config/ColumnType.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
package com.seafile.seadroid2.config;

import com.blankj.utilcode.util.CollectionUtils;

import java.util.List;

public class ColumnType {
public static final String INIT_FIELD = "0000";



public static final String TEXT = "text";
public static final String COLLABORATOR = "collaborator";
public static final String DATE = "date";
public static final String LONG_TEXT = "long-text";
public static final String NUMBER = "number";
public static final String DURATION = "duration";
public static final String SINGLE_SELECT = "single-select";
public static final String MULTIPLE_SELECT = "multiple-select";
public static final String IMAGE = "image";
public static final String FILE = "file";
public static final String EMAIL = "email";
public static final String URL = "url";
public static final String CHECKBOX = "checkbox";
public static final String RATE = "rate";

//Advanced
public static final String GEOLOCATION = "geolocation";
public static final String LINK = "link";
public static final String DIGITAL_SIGN = "digital-sign";
public static final String FORMULA = "formula";
public static final String LINK_FORMULA = "link-formula";
public static final String AUTO_NUMBER = "auto-number";
public static final String CTIME = "ctime";
public static final String MTIME = "mtime";
public static final String BUTTON = "button";
public static final String CREATOR = "creator";
public static final String LAST_MODIFIER = "last-modifier";


public final static List<String> ENABLE_TYPE_LIST = CollectionUtils.newArrayList(
TEXT,
COLLABORATOR,
DATE,
LONG_TEXT,
NUMBER,
DURATION,
SINGLE_SELECT,
MULTIPLE_SELECT,
IMAGE,
FILE,
EMAIL,
URL,
CHECKBOX,
RATE,
GEOLOCATION,
LINK,
DIGITAL_SIGN);
}
200 changes: 0 additions & 200 deletions app/src/main/java/com/seafile/seadroid2/framework/data/SeafRepo.java

This file was deleted.

Loading

0 comments on commit ae12e44

Please sign in to comment.