1
0
Fork 0
mirror of https://github.com/gsantner/dandelion synced 2024-11-25 05:42:10 +01:00

Moved WebClients and ChromeClients to webview package

This commit is contained in:
vanitasvitae 2016-10-01 00:24:53 +02:00
parent fec93a0660
commit e06e2f3ba1
8 changed files with 12 additions and 16 deletions

View file

@ -288,13 +288,6 @@ public class MainActivity extends AppCompatActivity
}
}
@Override
public void onConfigurationChanged(Configuration newConfig) {
AppLog.i(this, "onConfigurationChanged()");
super.onConfigurationChanged(newConfig);
}
private void setupNavigationSlider() {
ActionBarDrawerToggle toggle = new ActionBarDrawerToggle(
this, navDrawer, toolbarTop, R.string.navigation_drawer_open, R.string.navigation_drawer_close);

View file

@ -29,8 +29,8 @@ import com.github.dfa.diaspora_android.R;
import com.github.dfa.diaspora_android.activity.MainActivity;
import com.github.dfa.diaspora_android.data.AppSettings;
import com.github.dfa.diaspora_android.ui.ContextMenuWebView;
import com.github.dfa.diaspora_android.ui.CustomWebViewClient;
import com.github.dfa.diaspora_android.ui.ProgressBarWebChromeClient;
import com.github.dfa.diaspora_android.webview.CustomWebViewClient;
import com.github.dfa.diaspora_android.webview.ProgressBarWebChromeClient;
import com.github.dfa.diaspora_android.util.AppLog;
import java.io.File;

View file

@ -26,8 +26,8 @@ import com.github.dfa.diaspora_android.App;
import com.github.dfa.diaspora_android.R;
import com.github.dfa.diaspora_android.activity.MainActivity;
import com.github.dfa.diaspora_android.data.PodUserProfile;
import com.github.dfa.diaspora_android.ui.DiasporaStreamWebChromeClient;
import com.github.dfa.diaspora_android.ui.FileUploadWebChromeClient;
import com.github.dfa.diaspora_android.webview.DiasporaStreamWebChromeClient;
import com.github.dfa.diaspora_android.webview.FileUploadWebChromeClient;
import com.github.dfa.diaspora_android.util.AppLog;
import com.github.dfa.diaspora_android.util.DiasporaUrlHelper;
import com.github.dfa.diaspora_android.util.Helpers;
@ -51,7 +51,6 @@ public class DiasporaStreamFragment extends BrowserFragment {
private ValueCallback<Uri[]> imageUploadFilePathCallbackNew;
private ValueCallback<Uri> imageUploadFilePathCallbackOld;
private String mCameraPhotoPath;
private String sharedText;
@SuppressLint("SetJavaScriptEnabled")
@Override

View file

@ -52,6 +52,9 @@ public class HashtagListFragment extends CustomFragment {
final FollowedTagsAdapter adapter = new FollowedTagsAdapter(followedTags, onHashtagClickListener);
followedTagsRecyclerView.setAdapter(adapter);
//Set window title
getActivity().setTitle(R.string.nav_followed_tags);
}
@Override

View file

@ -16,7 +16,7 @@
If not, see <http://www.gnu.org/licenses/>.
*/
package com.github.dfa.diaspora_android.ui;
package com.github.dfa.diaspora_android.webview;
import android.content.Intent;
import android.net.Uri;
@ -37,6 +37,7 @@ public class CustomWebViewClient extends WebViewClient {
this.webView = webView;
}
//Open non-diaspora links in customtab/external browser
public boolean shouldOverrideUrlLoading(WebView view, String url) {
if (!url.contains(app.getSettings().getPodDomain())) {
Intent i = new Intent(MainActivity.ACTION_OPEN_EXTERNAL_URL);

View file

@ -1,4 +1,4 @@
package com.github.dfa.diaspora_android.ui;
package com.github.dfa.diaspora_android.webview;
import android.webkit.WebView;
import android.widget.ProgressBar;

View file

@ -1,4 +1,4 @@
package com.github.dfa.diaspora_android.ui;
package com.github.dfa.diaspora_android.webview;
import android.net.Uri;
import android.webkit.ValueCallback;

View file

@ -1,4 +1,4 @@
package com.github.dfa.diaspora_android.ui;
package com.github.dfa.diaspora_android.webview;
import android.view.View;
import android.webkit.WebChromeClient;