Tag

Fragment

0 views collected around this technical thread.

DaTaobao Tech
DaTaobao Tech
Feb 14, 2025 · Mobile Development

Resolving SurfaceView Flash Black Issues in Taobao Shopping Cart with Hybrid Architecture

The black‑flash in Taobao’s shopping‑cart tab occurs because SurfaceView’s independent surface is destroyed during fragment removal or activity switches, and four remedies are offered: keep the fragment alive with show/hide, capture and display a screenshot, toggle between ImageView and SurfaceView via Weex APIs, or convert SurfaceView to TextureView temporarily, each with performance, memory, and latency trade‑offs.

FragmentSurfaceViewUI
0 likes · 10 min read
Resolving SurfaceView Flash Black Issues in Taobao Shopping Cart with Hybrid Architecture
DaTaobao Tech
DaTaobao Tech
Feb 12, 2025 · Mobile Development

Optimizing Fragment Transition Animations in Android: Analysis and Solutions

The article examines why Android fragment transition animations lag compared to activity animations and proposes three remedies—delaying heavy UI work, feeding data frame‑by‑frame via Choreographer callbacks, and using an asynchronous SurfaceView snapshot—to achieve smoother, deterministic UI performance on low‑end devices.

ChoreographerFragmentSurfaceView
0 likes · 13 min read
Optimizing Fragment Transition Animations in Android: Analysis and Solutions
Sohu Tech Products
Sohu Tech Products
Aug 9, 2023 · Mobile Development

Understanding ViewPager2 OffscreenPageLimit and Its Performance Impact

This article explains the OffscreenPageLimit attribute of ViewPager2, how it controls off‑screen page loading, compares its default values with ViewPager, shows code implementations, analyzes performance trade‑offs, and provides practical recommendations for choosing an appropriate limit.

FragmentOffscreenPageLimitRecyclerView
0 likes · 16 min read
Understanding ViewPager2 OffscreenPageLimit and Its Performance Impact
Sohu Tech Products
Sohu Tech Products
Feb 1, 2023 · Mobile Development

Semi‑Automatic Declarative Show Exposure Tracking for Android Activities and Fragments

This article explains the differences between PV and show exposure points, introduces a PvTracker interface for semi‑automatic page‑view reporting, and presents a comprehensive solution that uses global activity lifecycle callbacks, fragment visibility detection, and Kotlin extension methods to achieve fully automated show event reporting in Android applications.

ActivityFragmentKotlin
0 likes · 12 min read
Semi‑Automatic Declarative Show Exposure Tracking for Android Activities and Fragments
Sohu Tech Products
Sohu Tech Products
Jul 20, 2022 · Mobile Development

Common Android Development Pitfalls and Solutions: Soft Keyboard, Merge Tag, LinearLayout, and Fragment Issues

This article discusses several frequent Android development challenges—including hiding the soft keyboard after activity finish, proper use of the merge tag, LinearLayout weight handling, and numerous Fragment lifecycle pitfalls—providing practical solutions, code snippets, and best‑practice recommendations to improve app stability and UI behavior.

FragmentLifecycleSoftKeyboard
0 likes · 13 min read
Common Android Development Pitfalls and Solutions: Soft Keyboard, Merge Tag, LinearLayout, and Fragment Issues
Tencent Music Tech Team
Tencent Music Tech Team
Nov 10, 2021 · Mobile Development

Android Routing Management: Activity, Fragment, and Hybrid Page Navigation

Android routing management separates native navigation—using Activity launch modes, the ActivityManagerService task stack, intents, and the Navigation component for fragments—from hybrid navigation, where Activities host WebView, Weex/React‑Native, or Flutter pages and communicate via intents, bridges, or platform channels to achieve flexible page routing.

ActivityFragmentHybrid
0 likes · 13 min read
Android Routing Management: Activity, Fragment, and Hybrid Page Navigation
Sohu Tech Products
Sohu Tech Products
Apr 14, 2021 · Mobile Development

Comprehensive Guide to Listening to Android Fragment Visibility

This article presents a complete solution for monitoring Fragment visibility in Android, covering simple replace operations, hide/show handling, ViewPager nesting, AndroidX adapter behaviors, and a reusable BaseVisibilityFragment implementation with Kotlin code examples.

FragmentKotlinLifecycle
0 likes · 12 min read
Comprehensive Guide to Listening to Android Fragment Visibility
Sohu Tech Products
Sohu Tech Products
Nov 18, 2020 · Mobile Development

Comprehensive Guide to Android Navigation Component: Usage, Deep Links, Safe Args, and Source Code Analysis

This article provides an in‑depth tutorial on Android’s Navigation component, covering core concepts, XML graph setup, fragment transactions, parameter passing via Bundle and Safe Args, deep‑link integration, animation configuration, stack management, and a detailed source‑code analysis for developers.

Deep LinkFragmentNavigation Component
0 likes · 27 min read
Comprehensive Guide to Android Navigation Component: Usage, Deep Links, Safe Args, and Source Code Analysis
Watermelon Video Tech Team
Watermelon Video Tech Team
Nov 29, 2019 · Mobile Development

Scene: ByteDance’s Open‑Source Android Single‑Activity Navigation and Composition Framework

Scene is an open‑source Android framework from ByteDance’s Xigua video team that provides lightweight, view‑based page navigation and composition for Single‑Activity applications, addressing Activity/Fragment limitations with flexible stack management, shared‑element animations, and ViewModel‑based communication.

FragmentSceneSingle Activity
0 likes · 14 min read
Scene: ByteDance’s Open‑Source Android Single‑Activity Navigation and Composition Framework
Beike Product & Technology
Beike Product & Technology
Jan 24, 2019 · Mobile Development

Simplifying Android Photo Capture with the PhotoTaker Utility

This article explains why traditional Android photo capture using Intents and onActivityResult is cumbersome, especially in list adapters, and introduces a Fragment‑based PhotoTaker utility that streamlines camera and gallery access, handles dynamic permissions, and works across Android versions.

CameraDynamic PermissionFragment
0 likes · 12 min read
Simplifying Android Photo Capture with the PhotoTaker Utility
JD Retail Technology
JD Retail Technology
Jul 5, 2018 · Mobile Development

Android Navigation Component: Introduction, Usage, and Source Code Analysis

This article provides a comprehensive guide to Android's Navigation component, covering its purpose, setup steps, XML graph configuration, fragment navigation, data passing methods, deep link handling, nested navigation, and an analysis of the underlying source code with practical Kotlin examples.

DeepLinkFragmentJetpack
0 likes · 11 min read
Android Navigation Component: Introduction, Usage, and Source Code Analysis