diff --git a/.idea/caches/gradle_models.ser b/.idea/caches/gradle_models.ser index 3add12d..2a2f3b6 100644 Binary files a/.idea/caches/gradle_models.ser and b/.idea/caches/gradle_models.ser differ diff --git a/app/build.gradle b/app/build.gradle index 61c079b..e905ada 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -6,8 +6,8 @@ android { applicationId "com.htetznaing.xgetterexample" minSdkVersion 17 targetSdkVersion 28 - versionCode 4 - versionName "1.4" + versionCode 5 + versionName "1.5" testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" } buildTypes { diff --git a/app/release/app-release.apk b/app/release/app-release.apk index 7709293..15a2b39 100644 Binary files a/app/release/app-release.apk and b/app/release/app-release.apk differ diff --git a/app/release/output.json b/app/release/output.json index dccaa98..d171dd0 100644 --- a/app/release/output.json +++ b/app/release/output.json @@ -1 +1 @@ -[{"outputType":{"type":"APK"},"apkInfo":{"type":"MAIN","splits":[],"versionCode":4,"versionName":"1.4","enabled":true,"outputFile":"app-release.apk","fullName":"release","baseName":"release"},"path":"app-release.apk","properties":{}}] \ No newline at end of file +[{"outputType":{"type":"APK"},"apkInfo":{"type":"MAIN","splits":[],"versionCode":5,"versionName":"1.5","enabled":true,"outputFile":"app-release.apk","fullName":"release","baseName":"release"},"path":"app-release.apk","properties":{}}] \ No newline at end of file diff --git a/app/src/main/java/com/htetznaing/xgetterexample/MainActivity.java b/app/src/main/java/com/htetznaing/xgetterexample/MainActivity.java index 4ee9e88..4b045cd 100644 --- a/app/src/main/java/com/htetznaing/xgetterexample/MainActivity.java +++ b/app/src/main/java/com/htetznaing/xgetterexample/MainActivity.java @@ -7,7 +7,6 @@ import android.net.Uri; import android.support.v7.app.AppCompatActivity; import android.os.Bundle; -import android.view.ContextThemeWrapper; import android.view.Menu; import android.view.MenuItem; import android.view.View; @@ -16,6 +15,8 @@ import android.widget.TextView; import android.widget.Toast; +import com.htetznaing.xgetter.OkRuLinks; +import com.htetznaing.xgetter.VkLinks; import com.htetznaing.xgetter.XGetter; import com.htetznaing.xgetterexample.Player.MyExoPlayer; @@ -50,6 +51,22 @@ public void onFbTaskCompleted(String sd, String hd) { } else done(null, null, null, false, true); } + @Override + public void onOkRuTaskCompleted(OkRuLinks okRuLinks) { + progressDialog.dismiss(); + if (okRuLinks.getHD()!=null){ + done(okRuLinks.getHD(),null,null,false,false); + } else done(null, null, null, false, true); + } + + @Override + public void onVkTaskComplete(VkLinks vkLinks) { + progressDialog.dismiss(); + if (vkLinks.getUrl720()!=null){ + done(vkLinks.getUrl720(),null,null,false,false); + } else done(null, null, null, false, true); + } + @Override public void onError() { progressDialog.dismiss(); @@ -93,7 +110,7 @@ public void vidcloud(View view) { } public void rapidvideo(View view) { - letGo("https://www.rapidvideo.com/v/FY1NF585GW"); + letGo("https://www.rapidvideo.com/v/FW5M4CBTFF"); } public void gdrive(View view) { @@ -112,6 +129,14 @@ public void mediafire(View view) { letGo("http://www.mediafire.com/file/dd00f818ybeu83x/"); } + public void okru(View view) { + letGo("https://ok.ru/video/1246547348046"); + } + + public void vk(View view) { + letGo("https://vk.com/video-94920838_456240508"); + } + public boolean checkInternet() { boolean what = false; CheckInternet checkNet = new CheckInternet(this); @@ -218,6 +243,9 @@ public void showAbout() { "SendVid\n" + "VidCloud\n" + "MegaUp\n" + + "Mediafire\n" + + "VK\n" + + "Ok.Ru" + "\n" + "Github Repo => https://github.com/KhunHtetzNaing/xGetter"; View view = getLayoutInflater().inflate(R.layout.done, null); diff --git a/app/src/main/res/layout/activity_main.xml b/app/src/main/res/layout/activity_main.xml index 3ec9aa5..3e9decf 100644 --- a/app/src/main/res/layout/activity_main.xml +++ b/app/src/main/res/layout/activity_main.xml @@ -46,8 +46,8 @@ android:layout_height="match_parent">