Android中如何实现模板activity?
大家讲道理
大家讲道理 2017-04-17 15:40:38
0
2
262
大家讲道理
大家讲道理

光阴似箭催人老,日月如移越少年。

reply all(2)
迷茫

If you just ask about the Taobao app, its product details page is actually a web page, so what should be discussed is the web page template. Activity only hosts the framework webview. If you are asking about using native Activity to implement a product details page similar to Taobao, then you have to consider more. First, summarize the common information of the products. For example, there are poster previews, keyword tags, and the increase or decrease in the number of shopping carts. They all have business information, product introductions, etc., and they are all displayed in fixed locations, so just define a fixed layout. The Activity receives different product IDs, requests the product details data of this ID from the background, and binds the corresponding Just display it. Of course, the actual situation is much more complicated. Different product categories should have different display methods, such as clothing and food. They may require different pages to distinguish the differences, so they need to be designed separately. E-commerce product detail pages are basically implemented as web pages, which are more flexible.

Peter_Zhu

If it is native NATIVE, use Fragment
If it is HTML5, use WebView

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!