fixed layout in accounts manager
This commit is contained in:
parent
e5f5db6d93
commit
9f75af1cf5
|
@ -1,18 +1,13 @@
|
||||||
package org.mariotaku.twidere.activity.support;
|
package org.mariotaku.twidere.activity.support;
|
||||||
|
|
||||||
import android.graphics.Rect;
|
|
||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
import android.support.v4.app.Fragment;
|
|
||||||
import android.support.v4.app.FragmentManager;
|
import android.support.v4.app.FragmentManager;
|
||||||
import android.support.v4.app.FragmentTransaction;
|
import android.support.v4.app.FragmentTransaction;
|
||||||
import android.support.v4.view.WindowCompat;
|
|
||||||
import android.support.v7.app.ActionBar;
|
import android.support.v7.app.ActionBar;
|
||||||
import android.view.MenuItem;
|
import android.view.MenuItem;
|
||||||
|
|
||||||
import org.mariotaku.twidere.R;
|
import org.mariotaku.twidere.R;
|
||||||
import org.mariotaku.twidere.fragment.iface.IBaseFragment;
|
|
||||||
import org.mariotaku.twidere.fragment.support.AccountsManagerFragment;
|
import org.mariotaku.twidere.fragment.support.AccountsManagerFragment;
|
||||||
import org.mariotaku.twidere.view.TintedStatusFrameLayout;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Accounts manager
|
* Accounts manager
|
||||||
|
@ -20,16 +15,6 @@ import org.mariotaku.twidere.view.TintedStatusFrameLayout;
|
||||||
*/
|
*/
|
||||||
public class AccountsManagerActivity extends BaseDialogWhenLargeActivity {
|
public class AccountsManagerActivity extends BaseDialogWhenLargeActivity {
|
||||||
|
|
||||||
@Override
|
|
||||||
public void onFitSystemWindows(Rect insets) {
|
|
||||||
super.onFitSystemWindows(insets);
|
|
||||||
final FragmentManager fm = getSupportFragmentManager();
|
|
||||||
final Fragment f = fm.findFragmentById(R.id.main_content);
|
|
||||||
if (f instanceof IBaseFragment) {
|
|
||||||
((IBaseFragment) f).requestFitSystemWindows();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onOptionsItemSelected(final MenuItem item) {
|
public boolean onOptionsItemSelected(final MenuItem item) {
|
||||||
switch (item.getItemId()) {
|
switch (item.getItemId()) {
|
||||||
|
@ -48,7 +33,7 @@ public class AccountsManagerActivity extends BaseDialogWhenLargeActivity {
|
||||||
if (actionBar != null) {
|
if (actionBar != null) {
|
||||||
actionBar.setDisplayHomeAsUpEnabled(true);
|
actionBar.setDisplayHomeAsUpEnabled(true);
|
||||||
}
|
}
|
||||||
setContentView(R.layout.activity_content_fragment);
|
setContentView(R.layout.activity_accounts_manager);
|
||||||
final FragmentManager fm = getSupportFragmentManager();
|
final FragmentManager fm = getSupportFragmentManager();
|
||||||
final FragmentTransaction ft = fm.beginTransaction();
|
final FragmentTransaction ft = fm.beginTransaction();
|
||||||
ft.replace(R.id.main_content, new AccountsManagerFragment());
|
ft.replace(R.id.main_content, new AccountsManagerFragment());
|
||||||
|
|
Loading…
Reference in New Issue