Microsoft releases Surface Duo 2 Android emulator for app developers Surface

    Microsoft releases Surface Duo 2 Android emulator for app developers

    Microsoft releases Surface Duo 2 Android emulator for app developers

    Category: Surface
    Posted: 24 Sep 2021

    Hello Android developers!

    At yesterday’s Microsoft event we introduced the new Microsoft Surface Duo 2.

    Today I’d like to invite developers to start building or enhancing apps for dual-screen devices like the Surface Duo, Surface Duo 2, and other foldables.

    Surface Duo 2

    The new Surface Duo 2 includes 5G support, three rear-facing cameras (including ultra-wide and telephoto), larger and brighter screens, a faster CPU, and a lot more! Learn more about Surface Duo 2 and pre-order on microsoft.com.


    Figure 1: Surface Duo 2

    Jetpack Window Manager

    The best way to adapt your applications for dual-screen, foldable, and large screen devices is to use Jetpack Window Manager. The FoldingFeature class provides device-specific information so that a single code base can adapt to different dual-screen and foldable devices, including all Surface Duo models.

    Hardware differences

    For app developers, the hardware differences will not materially affect the way you design and build dual-screen apps – the Jetpack Window Manager APIs will automatically provide the correct information for each device.

    Screen size

    The new Surface Duo has slightly different dimensions – the individual panes are a little taller and narrower, the hinge area is smaller, but the overall pixel count is larger! The Design Kit has been updated with these values:


    Figure 2: Surface Duo 2 screen dimensions

    Resource qualifiers

    The screen resolution changes are also reflected in the resource qualifiers you can use to load resources and layouts. The suffix sw720dp-2754×1800 combines the smaller axes from the Surface Duo range to match both devices, or you can create more specific qualifiers using the exact dimensions of each device.

    Surface Duo 2 Android emulator

    Download and install the latest Surface Duo Android emulator.


    Figure: Surface Duo 2 Android Emulator

    The emulator provides a complete dual-screen experience:

    • Running Android 11.
    • Simulates the hinge with a 3D modes view.
    • Supports Jetpack Window Manager APIs for adaptive UI layouts.
    • When used on a touch-screen host device like Microsoft Surface PCs, supports multi-touch and pen sensitivity.
    • Available for Windows, macOS, and Linux.
    • Works with Android Studio, Visual Studio, VSCode, and other IDEs used for Android app development.

    Develop like a pro on Surface Laptop Studio

    The Surface Duo developer experience team always meets developers where they are at: our emulator and tools run great on Windows, macOS, and Linux and we provide guidance and code samples across a range of Android-supported platforms and languages. For pure developer productivity, the new Surface Laptop Studio will be hard to beat. It has the performance, keyboard, and screen real estate to be a true programmer’s delight, but you can also pull the screen forward and use pressure-sensitive pen or multi-touch gestures to interact with the Android emulator to get an immersive debugging experience.


    Figure 3: Surface Laptop Studio

    Watch Scott Hanselman share his perspective on the Surface Laptop Studio as a developer platform during yesterday’s event.

    Developer samples

    We have a collection of samples demonstrating how to implement Jetpack Window Manager, or use the enhanced SlidingPaneLayout control to build responsive apps with Kotlin (or Java):


    Figure 4: samples that highlight dual-screen user experiences

    Jetpack Compose

    We’ve also created guidance for incorporating Window Manager with Jetpack Compose, including a TwoPaneLayout control that provides a responsive foundation for adaptive single-screen, dual-screen, foldable, and large screen Compose user interface layouts.


    Figure 5: Jetpack Compose TwoPaneLayout sample

    Cross-platform support

    Since the first Surface Duo launch, Microsoft has been committed to enabling developers to take advantage of the dual-screen device category, regardless of which development platform you use. We’ve updated our SDKs, documentation, and samples for Flutter, Xamarin, Unity, Uno Platform, and the web (including PWAs) to support the latest version of Jetpack Window Manager. No matter how you build your Android apps, we’re ready to help you adapt to the dual-screen and foldable ecosystem.

    Join us at DroidCon!

    The Surface Duo Developer Experience team will be speaking at a number of Android events this year. Visit droidcon.com to register for the conference closest to you, or check out the online options:

    Date Sign up Topic
    October 20th-22nd Berlin, Germany Target foldable Android devices using Jetpack Window Manager
    October 28th-29th London, UK Android foldable and dual-screen device support in Flutter
    November 10th-11th New York, USA Large screen and foldable UX for Android devices
    December 13th-14th San Francisco, USA Foldable support in Jetpack Compose

    Resources and feedback

    If you have any questions, or would like to tell us about your plans for dual-screen and foldable apps, use the feedback forum or message us on Twitter @surfaceduodev.

    Finally, please join us for our dual screen developer livestream at 11am (Pacific time) each Friday – mark it in your calendar and check out the archives on YouTube.


    Guy Merin
    Senior Director of Engineering, Surface Duo Developer Experience Team (DevX)


    Read more:
    Brink's Avatar Posted By: Brink
    24 Sep 2021


 

  Related Discussions
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 14:42.
Find Us




Windows 10 Forums