mirror of
https://github.com/M66B/FairEmail.git
synced 2026-04-04 16:16:33 +02:00
Added support for split screen
This commit is contained in:
@@ -44,6 +44,7 @@ import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.Button;
|
||||
import android.widget.ImageButton;
|
||||
import android.widget.LinearLayout;
|
||||
import android.widget.Toast;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
@@ -183,6 +184,15 @@ public class ActivityView extends ActivityBilling implements FragmentManager.OnB
|
||||
content_separator = findViewById(R.id.content_separator);
|
||||
content_pane = findViewById(R.id.content_pane);
|
||||
|
||||
if (!portrait && !landscape3 && Helper.isSplitScreen()) {
|
||||
View content_frame = findViewById(R.id.content_frame);
|
||||
ViewGroup.LayoutParams lparam = content_frame.getLayoutParams();
|
||||
if (lparam instanceof LinearLayout.LayoutParams) {
|
||||
((LinearLayout.LayoutParams) lparam).weight = 1;
|
||||
content_frame.setLayoutParams(lparam);
|
||||
}
|
||||
}
|
||||
|
||||
drawerLayout = findViewById(R.id.drawer_layout);
|
||||
|
||||
final ViewGroup childContent = (ViewGroup) drawerLayout.getChildAt(0);
|
||||
|
||||
Reference in New Issue
Block a user