diff --git a/res/layout/hello_world.xml b/res/layout/hello_world.xml index c738cb2f1..25d396656 100644 --- a/res/layout/hello_world.xml +++ b/res/layout/hello_world.xml @@ -1,18 +1,31 @@ - - - - + + + + - + + + - + - + diff --git a/src/org/linphone/BandwidthManager.java b/src/org/linphone/BandwidthManager.java index 2b2038b3f..abbbad55a 100644 --- a/src/org/linphone/BandwidthManager.java +++ b/src/org/linphone/BandwidthManager.java @@ -31,6 +31,7 @@ public class BandwidthManager { public static final int HIGH_RESOLUTION = 0; public static final int LOW_RESOLUTION = 1; public static final int LOW_BANDWIDTH = 2; + private static final boolean portraitMode = true; // FIXME: preference? private static final int[][] bandwidthes = {{256,256}, {128,128}, {80,80}}; private static BandwidthManager instance; @@ -81,7 +82,7 @@ public class BandwidthManager { lc.setPreferredVideoSize(targetVideoSize); VideoSize actualVideoSize = lc.getPreferredVideoSize(); if (!targetVideoSize.equals(actualVideoSize)) { - lc.setPreferredVideoSize(VideoSize.createStandard(VideoSize.QCIF)); + lc.setPreferredVideoSize(VideoSize.createStandard(VideoSize.QCIF, portraitMode)); } } @@ -105,9 +106,9 @@ public class BandwidthManager { private VideoSize getProfileVideoSize(int profile) { switch (profile) { case LOW_RESOLUTION: - return closestVideoSize(VideoSize.createStandard(VideoSize.QCIF)); + return closestVideoSize(VideoSize.createStandard(VideoSize.QCIF, portraitMode)); case HIGH_RESOLUTION: - return closestVideoSize(VideoSize.createStandard(VideoSize.QVGA)); + return closestVideoSize(VideoSize.createStandard(VideoSize.QVGA, portraitMode)); default: throw new RuntimeException("profile not managed : " + profile); } @@ -124,6 +125,6 @@ public class BandwidthManager { } } - return VideoSize.createStandard(VideoSize.QCIF); + return VideoSize.createStandard(VideoSize.QCIF, portraitMode); } } diff --git a/src/org/linphone/DialerActivity.java b/src/org/linphone/DialerActivity.java index f6411951d..07e0656f0 100644 --- a/src/org/linphone/DialerActivity.java +++ b/src/org/linphone/DialerActivity.java @@ -521,6 +521,7 @@ public class DialerActivity extends Activity implements LinphoneCoreListener { if (mWakeLock.isHeld())mWakeLock.release(); mSpeaker.setChecked(false); routeAudioToReceiver(); + BandwidthManager.getInstance().setUserRestriction(false); } private void routeAudioToSpeaker() { if (Integer.parseInt(Build.VERSION.SDK) <= 4 /*0?mySipAddressWidget.getText().toString():null; + String myPassword = mySipPasswordWidget.getText().length()>0?mySipPasswordWidget.getText().toString():null; + tutorial.launchTutorial(sipAddressWidget.getText().toString(), myIdentity, myPassword); mHandler.post(new Runnable() { public void run() { buttonCall.setEnabled(true); diff --git a/submodules/linphone b/submodules/linphone index cdba824dc..b2e49a28c 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit cdba824dc5673de0250f46b909c4bcde1b3388ad +Subproject commit b2e49a28c760f7b010ebf31b312edbac660f9894