freepeople性欧美熟妇, 色戒完整版无删减158分钟hd, 无码精品国产vα在线观看DVD, 丰满少妇伦精品无码专区在线观看,艾栗栗与纹身男宾馆3p50分钟,国产AV片在线观看,黑人与美女高潮,18岁女RAPPERDISSSUBS,国产手机在机看影片

正文內(nèi)容

基于安卓的圖片瀏覽器的設(shè)計(jì)與實(shí)現(xiàn)-資料下載頁(yè)

2024-11-07 21:22本頁(yè)面

【導(dǎo)讀】Android一詞的本義指“機(jī)器人”,同時(shí)也是Google于2020年11月5日宣布的基于Linux. 號(hào)稱是首個(gè)為移動(dòng)終端打造的真正開放和完整的移動(dòng)軟件。目前,最新版本為AndroidIce. Android系統(tǒng)開發(fā)運(yùn)營(yíng),它采用了軟件堆層的架構(gòu),主要分。底層以Linux內(nèi)核工作為基礎(chǔ),由C語(yǔ)言開發(fā),只提供基本功能;中間層包括函。數(shù)庫(kù)Library和虛擬機(jī)VirtualMachine,由C++開發(fā)。短信程序等,應(yīng)用軟件則由各公司自行開發(fā),以Java作為編寫程序的一部分。全球?yàn)閿?shù)眾多的移動(dòng)電話用戶正在使用各種基于Android的電話。讓不依賴于設(shè)備甚至平臺(tái)。出于這個(gè)目的,Android將補(bǔ)充,而不會(huì)替代谷歌。長(zhǎng)期以來(lái)奉行的移動(dòng)發(fā)展戰(zhàn)略:通過(guò)與全球各地的手機(jī)制造商和移動(dòng)運(yùn)營(yíng)商結(jié)成合作伙伴,開發(fā)既有用又有吸引力的移動(dòng)服務(wù),并推廣這些產(chǎn)品。2020年初數(shù)據(jù)顯示,僅正式上市兩年的操作系統(tǒng)Android已經(jīng)超越稱霸十年的塞班系統(tǒng),使之躍居全球最受歡迎的智能手機(jī)平臺(tái)。Android的主要競(jìng)爭(zhēng)對(duì)手是蘋果公司的iOS以及RIM

  

【正文】 e = new DOMSource(doc)。 StreamResult result = new StreamResult(xmlPath)。 (source, result)。 } catch (ParserConfigurationException e) { ()。 } catch (SAXException e) { ()。 } catch (IOException e) { ()。 } catch (TransformerConfigurationException e) { ()。 } catch (TransformerException e) { ()。 } } /*獲取歷史記錄 */ public static ListHistory readXml(InputStream in){ ListHistory histories= null。 History history = null。 XmlPullParser parser = ()。 try { un paerdstc233。olmbizvg,qfx39。.10D:OG243。23232。%yRI231。()jTh5237。C224。 (in,UTF8)。 int eventCode = ()。 while(eventCode!=){ switch (eventCode) { case : //當(dāng)讀取到的是開始標(biāo)簽, new 一個(gè) History 對(duì)象,對(duì)其賦值 if(history.equals(())){ history = new History()。 }else if(name.equals(())){ if(history!=null){ (new String(()))。 } }else if(path.equals(())){ if(history!=null){ (new String(()))。 } }else if(date.equals(())){ if(history!=null){ (new String(()))。 } } break。 case : //當(dāng)讀到的是結(jié)束標(biāo)簽,將 History 對(duì)象加入 ListHistory列表 if(history.equals(())amp。amp。history!=null){ (history)。 history = null。 } break。 case : //當(dāng)讀取到的是文件頭 histories = new ArrayListHistory()。 重慶郵電大學(xué)本科畢業(yè)設(shè)計(jì)(論文) un paerdstc233。olmbizvg,qfx39。.10D:OG243。23232。%yRI231。()jTh5237。C224。27 break。 } eventCode = ()。 } return histories。 } catch (Exception e) { return null。 }finally{ try { ()。 } catch (IOException e) { ()。 } } } } 二、 頁(yè)面布局 xml 本應(yīng)用一共有 3 個(gè)頁(yè)面, (瀏覽圖片頁(yè)面)、 (瀏覽歷史頁(yè)面)、 (歷史圖片瀏覽頁(yè)面)。由于瀏覽歷史頁(yè)面和歷史圖片瀏覽頁(yè)面布局與瀏覽圖片頁(yè)面較為重復(fù),所以這里就只將瀏覽圖片頁(yè)面和歷史記錄頁(yè)面代碼貼出。 在 頁(yè)面,采用了 ImageSwitcher+Gallery 組件框架設(shè)計(jì),其布局代碼如下: ?xml version= encoding=utf8? LinearLayout xmlns:android= android:layout_width=fill_parent android:layout_height=fill_parent android:layout_gravity=top android:orientation=vertical ImageSwitcher android:id=@+id/imageswitcher un paerdstc233。olmbizvg,qfx39。.10D:OG243。23232。%yRI231。()jTh5237。C224。 android:layout_width=match_parent android:layout_height=400dp android:layout_gravity=top|left android:orientation=vertical/ Gallery android:id=@+id/gallery android:layout_width=match_parent android:layout_height=match_parent android:layout_gravity=bottom|left android:background=55000000 android:orientation=vertical/ /LinearLayout 瀏覽歷史界面采用的是 ListActivity 控件,其中的 getView()方法獲取如下 的布局: ?xml version= encoding=utf8? LinearLayout xmlns:android= android:orientation=vertical android:layout_width=wrap_content android:layout_height=wrap_content TextView android:id=@+id/title android:layout_width=wrap_content android:layout_height=wrap_content android:textColor=FFFFFFFF android:textSize=15dp / TextView android:id=@+id/info android:layout_width=wrap_content android:layout_height=wrap_content android:textColor=808080 android:textSize=13dp / /LinearLayout 三、 后臺(tái) Activity 重慶郵電大學(xué)本科畢業(yè)設(shè)計(jì)(論文) un paerdstc233。olmbizvg,qfx39。.10D:OG243。23232。%yRI231。()jTh5237。C224。29 圖片瀏覽頁(yè)面采用的 ImageSwitcher+Gallery 布局,后臺(tái) Activity 中需要注冊(cè)這 2 個(gè)控件。 ImageSwicher 的注冊(cè),工廠設(shè)置: /*獲取 ImageSwitcher 控件 ,設(shè)置工廠并設(shè)置動(dòng)畫效果 */ is = (ImageSwitcher) findViewById()。 (this)。 ((this, ))。 ((this, ))。 ()。 Gallery 的注冊(cè),綁定自定義適配器: /*獲取 Gallery 控件,設(shè)置 ImageAdapter,添加 OnItemClick 事件監(jiān)聽 */ gallery = (Gallery) findViewById()。 ImageAdapter ia = new ImageAdapter(this)。 (ia)。 (this)。 (1)。//設(shè)置默認(rèn)選中的圖片 自定義適配器: /*ImageAdapter*/ public class ImageAdapter extends BaseAdapter{ private Context context。 int mGalleryItemBackground 。 public ImageAdapter(Context c){ context = c。 TypedArray ta = obtainStyledAttributes()。 mGalleryItemBackground = (, 0)。 } @Override public int getCount() { return 。//傳入一個(gè)很大的值以實(shí)現(xiàn)循環(huán)滑動(dòng) un paerdstc233。olmbizvg,qfx39。.10D:OG243。23232。%yRI231。()jTh5237。C224。 } @Override public Object getItem(int position) { return position。 } @Override public long getItemId(int position) { return position。 } @Override public View getView(int position, View arg1, ViewGroup arg2) { ImageView i = new ImageView(context)。 /*當(dāng) images 文件夾下無(wú) 圖片時(shí)調(diào)用 */ if(()){ ()。 return i。 } /*當(dāng) images 文件夾下有圖片時(shí)調(diào)用 */ else{ ((position%()))。 (true)。 (new ( , ))。 (mGalleryItemBackground)。 return i。 } } } 重慶郵電大學(xué)本科畢業(yè)設(shè)計(jì)(論文) un paerdstc233。olmbizvg,qfx39。.10D:OG243。23232。%yRI231。()jTh5237。C224。31 瀏覽歷史 Activity 采 用 繼 承 ListActivity, 這個(gè) Activity 重寫了onListItemClick(ListView l, View v, int position, long id)方法 ,并綁定了自定義適配器,核心代碼如下: /*自定義 Adapter*/ public class MyAdapter extends BaseAdapter{ private LayoutInflater mInflater。 public MyAdapter(Context context){ = (context)。 } @Override public int getCount() { return ()。 } @Override public Object getItem(int arg0) { return null。 } @Override public long getItemId(int arg0) { return 0。 } @Override public View getView(int position, View convertView, ViewGroup parent) { ViewHolder holder = null。 if (convertView == null) { holder=new ViewHolder()。 convertView = (, null)。 = (TextView)()。 = (TextView)()。 (holder)。 }else { un paerdstc233。olmbizvg,qfx39。.10D:OG243。23232。%yRI231。()jTh5237。C224。 holder = (ViewHolder)()。 } ((String)(position).get(title))。 ((String)(position).get(info))。
點(diǎn)擊復(fù)制文檔內(nèi)容
畢業(yè)設(shè)計(jì)相關(guān)推薦
文庫(kù)吧 www.dybbs8.com
備案圖鄂ICP備17016276號(hào)-1