블로그 이미지
엡뽀
피난(?) 오신걸 환영합니다.

calendar

1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31

Notice

2013. 1. 16. 10:03 News

몇일전 소니에서 CJ E&M 넷마블에서 서비스 중인 다함께차차차 게임을 표절로 서비스 중지 요청이 있었습니다.

(기사 원문 : http://www.seoul.co.kr/news/newsView.php?id=20130115500001&ref=nc)


이에 따른 CJ E&M 넷마블측에서는 서비스 중단은 없을것이며, 소니의 법적대응에도 강경히 맞설 것이라고 합니다.

(기사 원문 : http://media.daum.net/digital/newsview?newsid=20130115115506454)



==============================================================================================


한명의 개발자로써 나의 결과물(지적 소유권)이 중요하듯이 다른 사람의 결과물(지적 소유권)이 중요 한건 당연한 것일텐데

"난 모르오" 식의 대응은 정말 양심없는게 아닐까합니다. 


협상을 통해 서비스는 이어가더라도, 표절과 관련해서는 CJ E&M에서의 명확한 해명이 필요하지 않을까요?


'News' 카테고리의 다른 글

구글 글래스 실제 작동영상  (0) 2013.02.21
posted by 엡뽀
2013. 1. 3. 20:31 Programing/Android

안녕하세요. 블로거 엡뽀입니다. 


지난 Android UI 만들기 포스팅을 하면서 오픈 소스를 사용한 일이 있었는데, GitHub 사용법을 몰라서 그저 무식하게 파일 복사, 붙여넣기로 포스팅을 진행하였습니다. 하지만 쪼금만 알아보니 이렇게 번거롭게 할 필요없이. 간단하게 오픈 소스를 사용하는 방법을 알게 되어 GitHub에 관한 간단한 포스팅과 오픈 소스 프로젝트 (android-view-flow)를 내 프로젝트에 추가하여 빌드 하는 포스팅을 하도록 하겠습니다. 



1. GitHub 


GitHub를 설명하기 전에 앞서, Git에 관하여 설명을 하겠습니다. Git란 분산저장소로 일종의 저장소라고 보시면 됩니다. 마치 웹하드 처럼  특정 컴퓨터(서버)에 파일을 저장하는 저장소의 일종입니다. 


본래 Git는 리눅스 OS의 기능으로, 여러가지 명령어를 이용하여, 파일들을 다른 서버로 저장하던가, 내 컴퓨터로 다운을 받던가, 내컴퓨터에 있는 파일을 업로드 등등 여러가지 작업을 할 수 있습니다.  다만 이러한 일련의 작업들이 터미널 창을 이용하여 명령어로만 이루어 진다는 것이죠. 또한 리눅스 OS이기에 윈도우에선 사용 할 수 없습니다. (하지만 사실, 윈도우용 Git도 나온 상태입니다.) 이러한 Git 기능을 쫌더 편리하고 운영체제 상관없이 동작 하게 하는 웹서버에서 동작하는 Git가 바로  GitHub가 아닌가 합니다. => 그저 막연한 추측입니다. 


결론적으로 한 프로젝트를 여러 개발자들이 개발을 하여 파일 SVN(Subversion)을 할 수 있도록 하여주는 기능이 Git 같습니다. 

(제가 참고 하였던 블로그엔 SVN 개념이 Git를 이해하는데 방해한다고 하던데; 제가 Git에 대한 명확한 개념이 잡히지 않아  저말 말고는 표현하기가 힘드네요;;)


그리고 이러한 Git 명령어들을 간편하게 이용할 수 있는 웹사이트가 GitHub 입니다. 즉 단순히 오픈 소스를 사용하기만 하거나 소스 분석만 할 경우에는 이클립 + Git 연동이 전혀 필요가 없습니다.



2. Anroid Project에 오픈소스 프로젝트 추가하기.


이제때까지의 포스팅에서는 clone을 통한 소스파일을 다운 받고, res소스 파일 및 소스 파일들을 복사 붙여넣기를 통해서 오픈소스를 프로젝트에 추가하였었는데요. 이건 저의 심각한 착각으로 일어난 일이었습니다. ㅜㅜ 


이클립스와 GitHub 연동을 하여야만 Android 프로젝트에 오픈 소스를 추가 할 수 있는줄 알아서 덜컥 겁부터 먹고서는 프로젝트에 추가하지 못하였었는데요, 알고보니 Android 프로젝트에 오픈소스를 단순히 사용만 할 경우에는 이클립스 + GitHub 연동이 전혀 필요가 없더군요.

다만 사용방법이 오픈소스마다 다른 것이었습니다. 


그리고  오픈소스마다 해당 사용법을 친절히 안내하고있는 상태구요. android-view-flow 오픈 소스 같은 경우엔 아래와 같이 설명이 나와있는데.



View Flow for Android

ViewFlow is an Android UI widget providing a horizontally scrollable ViewGroup with items populated from an Adapter. Scroll down to the bottom of the page for a screen shot.

The component is a Library Project. This means that there's no need to copy-paste resources into your own project, simply add the viewflow component as a reference to any project.


내용을 요약하여 보자면, "이 오픈소스 프로젝트는 Library Project이다. 리소스 파일들을 너의 프로젝트에 복사 붙여넣기 할 필요 없다." 정도가 되겠네요. 그렇습니다. 복사 붙여넣기는 뻘짓이된거죠. (예외적으로 복사 붙여넣기 해야하는 프로젝트도 있습니다.)


그리하여 새로운 프로젝트를 하나 만들고 해당 프로젝트에 android-view-flow 오픈소스를 추가하여 보도록 하겠습니다. 



(1) 프로젝트 생성




프로젝트 이름은 LibraryProject 로 설정하였구요. 그외에는 별다른 특이 사항이 없어서 그저 Next 버튼 연타 ㅎㅎ



(2) android-view-flow 프로젝트 소스 import (해당 소스 파일 다운 받는건 "Android UI를 만들어 보자 [3] - Tabbar 만들기 - "을 참고 하세요)






(2) LibraryProject에 viewflow 프로젝트 추가하기









(3) 최종결과





위 결과와 같이 프로젝트의 속성에서 Library 프로젝트를 추가하여 매우 간단하게 자기의 프로젝트에 추가 할 수 있습니다. gen 폴더에 res 관련된 데이터도 다 들어감은 물론, 소스들 까지 한꺼번에 추가하게 되는것이죠;


이러한 결과 이제껏 저의 포스팅은 절반이 쓸모없는 포스팅이 되었을뿐만 아니라 괜히 멍청한 포스팅 때문에 손발이 고생하셨을 분들에게 죄송할 따름이네요 ㅜㅜ 


다음 포스팅 부터는 확실하게 알아보고 포스팅을 하도록 유의하겠습니다~!!! 





posted by 엡뽀
2012. 12. 31. 17:20 Programing/Android


드디어 Android UI 만들어 보자의 마지막 포스팅이네요...;; 개인적으로 시간이 잘 안난것도 이유가 되겠지만 더 큰 이유는 귀찮니즘 때문에 너무 질질 끌어왔었네요;; (이 Androud UI 만들기 포스팅만 몇주를 하고있는 것같은;;;)


다시 한번 마음을 다잡으며 포스팅을 열심히 해볼렵니다. 아자아자!! ㅎㅎ



다시 본론으로 넘어와서, 이전 포스팅까지의 내용을 정리하여 보면, Activity를 두개 만들어서, 하나에선 기본 뷰들만 나타나고, 다른 하나에서는 리스트 뷰가 나타나도록 구성한뒤, 기본 뷰에서 Action bar를 통하여 리스트 뷰의 엑티비티가 실행되도록 프로젝트를 작성하였습니다. 


여기에 Tabbar를 추가하여 두개의 엑티비티로 되어있는 프로젝트를 하나의 엑티비티에서 두개의 뷰로 볼수있는 구조로 변경하도록 하겠습니다.  단 이 Tabbar도 오픈소스를 적용하여 진행하도록 하겠습니다. ( 처음 계획은 오픈 소스는 살며시 스쳐 지나가겠금 할려했었는데 자꾸만 오픈소스를 추가 하게 되네요;; github 도 쓸줄도 모르면서 ㅜㅜ)




▶android-viewflow 오픈소스

URL : https://github.com/pakerfeldt/android-viewflow

 




벌써 3번째 오픈 소스 사용이니 파일 복사 부분은 간략히만 짚고 넘어가겠습니다.




res\values\attrs.xml 내용 복사

    <declare-styleable name="ViewFlow">
        <attr name="sidebuffer" format="integer" />
    </declare-styleable>
    <declare-styleable name="CircleFlowIndicator">
        <attr name="activeColor" format="color" />
        <attr name="inactiveColor" format="color" />
        <attr name="radius" format="dimension" />
		<attr name="centered" format="boolean" />
		<attr name="fadeOut" format="integer" />
		<attr name="inactiveType">
			<flag name="stroke" value="0" />
			<flag name="fill" value="1" />
		</attr>
		<attr name="activeType">
			<flag name="stroke" value="0" />
			<flag name="fill" value="1" />
		</attr>
    </declare-styleable>    
    <declare-styleable name="TitleFlowIndicator">
        <attr name="titlePadding" format="dimension" />
        <!-- Left/right padding of not active view titles. -->
        <attr name="clipPadding" format="dimension" />
        <attr name="selectedColor" format="color" />
        <attr name="selectedBold" format="boolean" />
        <attr name="selectedSize" format="dimension" />
        <attr name="textColor" format="color" />
        <attr name="textSize" format="dimension" />
        <attr name="footerLineHeight" format="dimension" />
        <attr name="footerColor" format="color" />
        <attr name="footerTriangleHeight" format="dimension" />
        <attr name="customTypeface" format="string" />
    </declare-styleable>


프로젝트에 org.taptwo.android.widget 패키지 추가


src\org\taptwo\android\widget\ 파일들 전체 복사


p.s) 소스파일들을 추가 하시게 되면, 소스에 오류가 나타납니다. 패키지 명이 달라서 나타나는 증상이니, 

import org.taptwo.android.widget.viewflow.R; 이분을 제거 하고 다시 패키지명.R을 임포트 하시면 됩니다. (간단하게 이클립스에서 Ctrl + Shift + O 한번  하시면 됩니다.)




그럼 이것으로 오픈 소스를 사용할 준비는 완료되었으니, 기존의 소스들을 수정 하도록 하겠습니다.


1. activity_main.xml 파일 수정


- activity_main.xml -

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res/blog.example.androidui"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="fill_parent"
    android:layout_height="fill_parent"
    android:orientation="vertical" >
    
    <com.markupartist.android.widget.ActionBar
        android:id="@+id/actionbar"
        style="@style/ActionBar" />

    
    <org.taptwo.android.widget.ViewFlow
        android:id="@+id/viewflow"
		android:duplicateParentState="true" 
		android:layout_width="fill_parent" 
		android:layout_height="0dip"
		android:layout_weight="1">
	    
	</org.taptwo.android.widget.ViewFlow>
     <View
        android:layout_width="fill_parent"
        android:layout_height="2dip"
        android:background="#FFFF0000"
        />
    <LinearLayout android:layout_width="fill_parent"
		android:gravity="center_horizontal" android:id="@+id/header_layout"
		android:orientation="vertical" 
		android:layout_height="wrap_content">
		
        <org.taptwo.android.widget.TitleFlowIndicator
			android:id="@+id/viewflowindic" 
			android:layout_height="48dip"
			android:layout_width="fill_parent"
			app:footerLineHeight="2dp"
			app:footerTriangleHeight="10dp" 
			app:textColor="#A0FF0000" 
			app:selectedColor="#FFFF0000" 
			app:footerColor="#FFFF0000" 
			app:titlePadding="10dp" 
			app:textSize="17dp" app:selectedSize="18dp" 
			android:layout_marginTop="10dip" 
			app:clipPadding="5dp">
		</org.taptwo.android.widget.TitleFlowIndicator>

	</LinearLayout>

</LinearLayout>


우선 Action Bar 아래에 나오던 기본 뷰들을 전부 지웠구요, 그 부분에 viewflow 와 TitleFlowIndicator가 나타나도록 수정하였고, 뷰들의 속성 값들을 수정하였습니다.

 

자 그런데 여기서 TitleFlowIndicator 속성을 보시게되면 app: 이라는 접두어가 붙은 속성들이 등장하게됩니다. 

이 android-viewflow 오픈 소스는 app 이라는 xml 네임스페이스를 추가하여 view들의 속성을 지정하고있는데요. 이에 따라 android-viewflow 의 객체를 포함하는 최상위 view는 (여기선 LinearLayout 가 되겠지요.)  'xmlns' 라는 속성값을 통해 app 이라는 네임스페이스를 아래와 같이 추가 해주어야 합니다. 


xmls:app = "http://schemas.android.com/apk/res/프로젝트 패키지명"


p.s) 그런데 네임스페이스라고 보는게 옳은건지 잘모르겠네요;; 그저 이해를 돕기 위해 쓴 말이라고 생각하시면 될 것같습니다. 




2. default.xml 파일 추가


-default.xml-

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="fill_parent"
    android:layout_height="wrap_content"
    android:orientation="vertical" >
    
    <LinearLayout
        android:layout_width="fill_parent"
        android:layout_height="0dip"
        android:layout_marginLeft="16dip"
        android:layout_marginRight="16dip"
        android:layout_marginTop="30dip"
        android:layout_weight="1"
        android:orientation="vertical" >

        <TextView
            android:layout_width="fill_parent"
            android:layout_height="wrap_content"
            android:layout_marginTop="10dip"
            android:text="@string/session"
            android:textColor="#000000"
            android:textSize="22sp" />

        <View
            android:layout_width="fill_parent"
            android:layout_height="1dip"
            android:background="#000000" />

        <LinearLayout
            android:layout_width="fill_parent"
            android:layout_height="48dip"
            android:baselineAligned="true" >

            <EditText
                android:layout_width="0dip"
                android:layout_height="wrap_content"
                android:layout_marginBottom="4dip"
                android:layout_marginRight="4dip"
                android:layout_marginTop="4dip"
                android:layout_weight="1"
                android:hint="@string/hint" />

            <ImageView
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_margin="8dip"
                android:contentDescription="@string/modify"
                android:src="@drawable/content_edit" />
        </LinearLayout>

        <LinearLayout
            android:layout_width="fill_parent"
            android:layout_height="48dip" >

            <EditText
                android:layout_width="fill_parent"
                android:layout_height="wrap_content"
                android:layout_marginBottom="4dip"
                android:layout_marginRight="4dip"
                android:layout_marginTop="4dip"
                android:hint="@string/hint" />
        </LinearLayout>

        <TextView
            android:layout_width="fill_parent"
            android:layout_height="wrap_content"
            android:layout_marginTop="10dip"
            android:text="@string/session"
            android:textColor="#000000"
            android:textSize="22sp" />

        <View
            android:layout_width="fill_parent"
            android:layout_height="1dip"
            android:background="#000000" />

        <LinearLayout
            android:layout_width="fill_parent"
            android:layout_height="48dip"
            android:baselineAligned="true" >

            <Spinner
                android:id="@+id/androidui_sp_1"
                android:layout_width="0dip"
                android:layout_height="wrap_content"
                android:layout_marginBottom="4dip"
                android:layout_marginRight="4dip"
                android:layout_marginTop="4dip"
                android:layout_weight="1" />

            <Spinner
                android:id="@+id/androidui_sp_2"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_marginBottom="4dip"
                android:layout_marginLeft="4dip"
                android:layout_marginTop="4dip" />
        </LinearLayout>

        <LinearLayout
            android:layout_width="fill_parent"
            android:layout_height="48dip"
            android:baselineAligned="true" >

            <EditText
                android:layout_width="0dip"
                android:layout_height="wrap_content"
                android:layout_marginBottom="4dip"
                android:layout_marginRight="4dip"
                android:layout_marginTop="4dip"
                android:layout_weight="1"
                android:hint="@string/hint" />

            <Button
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_marginBottom="4dip"
                android:layout_marginLeft="4dip"
                android:layout_marginTop="4dip"
                android:text="@string/send" />
        </LinearLayout>
    </LinearLayout>

</LinearLayout>


별거 없습니다. 그냥 기존 activity_main.xml 에있던 기존 뷰들로 새로운 xml 파일을 하나 더 만들었습니다. 



3. activity_list.xml 파일 수정

- activity_list.xml -

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="fill_parent"
    android:layout_height="fill_parent"
    android:orientation="vertical" >
    
    <com.markupartist.android.widget.PullToRefreshListView
        android:id="@+id/android:list"
        android:layout_height="fill_parent"
        android:layout_width="fill_parent"
        android:cacheColorHint ="#00000000"
        />
	
</LinearLayout>


이것도 별거 없습니다. 기존 소스에선 ActionBar와 Textview로 만들어진 네이게이션바를 빼고, 속성을 몇가지 수정한게 전부입니다. 



4. ViewFlowAdapter 구현


viewflow 클래스는 listview 처럼 Adapter를 통하여 데이터 및 뷰를 보여주고있습니다. 이러한 이유때문에 activity_main.xml 파일 외에 두개의 xml 파일이 추가적으로 필요하여, default.xml 파일을 새로 만들고, activity_list.xml 파일을 수정하였습니다. 



또한 TitleFlowIndicator 클래스는 TitleProvider 인터페이스를 구현한 클래스로 부터 데이터를 읽어들이는데 ViewFlowAdapter 클래스가 TitleProvider 인터페이스까지 구현하도록 하겠습니다.


- ViewFlowAdapter.java -

package blog.example.androidui;

import org.taptwo.android.widget.TitleProvider;

import android.content.Context;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.BaseAdapter;

public class ViewFlowAdapter extends BaseAdapter implements TitleProvider {

	private LayoutInflater mInflater;
	
	private String[] titles = {"View1", "View2"};    //타이틀
	
	public ViewFlowAdapter(Context context){
		mInflater = (LayoutInflater) context.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
	}
	
	
	@Override
	public int getCount() {
		return titles.length;    //아이템 갯수.
	}

	@Override
	public Object getItem(int position) {
		return position;
	}

	@Override
	public long getItemId(int position) {
		return position;
	}

         /* 포지션에 따라 생성하는 view를 다르게 설정 */
 
	@Override
	public View getView(int position, View convertView, ViewGroup parent) {
		if(convertView == null){
			if(position == 0){	//기본뷰
				convertView = mInflater.inflate(R.layout.default_view, null);
				
			}else{	//리스트뷰
				convertView = mInflater.inflate(R.layout.activity_list, null);
			}
		}
		
		return convertView;
	}

	@Override
	public String getTitle(int position) {    //타이틀 값.
		return titles[position];
	}

}


ViewflowAdapter 클래스는 BaseAdapter를 상속받아 만든 클래스이기 때문에 특별히 따로 설명드릴만한건 없는것 같습니다. 

다만 getView 메소드에서 포지션값에 따라 view가 다르게 생성되는 부분만 유의 하시면 될것같습니다. 



4. MainActivity 수정


- MainActivity.java -

package blog.example.androidui;

import java.util.Arrays;
import java.util.LinkedList;
import java.util.Vector;

import org.taptwo.android.widget.TitleFlowIndicator;
import org.taptwo.android.widget.ViewFlow;

import android.app.Activity;
import android.content.Context;
import android.content.Intent;
import android.content.res.Configuration;
import android.os.AsyncTask;
import android.os.Bundle;
import android.widget.ArrayAdapter;
import android.widget.Spinner;

import com.markupartist.android.widget.ActionBar;
import com.markupartist.android.widget.ActionBar.Action;
import com.markupartist.android.widget.ActionBar.IntentAction;
import com.markupartist.android.widget.PullToRefreshListView;
import com.markupartist.android.widget.PullToRefreshListView.OnRefreshListener;

public class MainActivity extends Activity {

	private ViewFlow viewFlow;  //오픈 소스 객체.

	
	//listview 관련
	private PullToRefreshListView list = null;
	
	private String[] mStrings = {
            "Abbaye de Belloc", "Abbaye du Mont des Cats", "Abertam",
            "Abondance", "Ackawi", "Acorn", "Adelost", "Affidelice au Chablis",
            "Afuega'l Pitu", "Airag", "Airedale", "Aisy Cendre",
            "Allgauer Emmentaler"};
	private LinkedList<String> mListItems;
	
	@Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);
        final ActionBar actionBar = (ActionBar) findViewById(R.id.actionbar);
        actionBar.setTitle("Home");
        
        final Action shareAction = new IntentAction(this, createShareIntent(), R.drawable.ic_title_share_default);
        actionBar.addAction(shareAction);
        
        //ListActivity를 실행하는 Action 주석 처리.
        //Intent intent = new Intent(this, ListViewActivity.class);
        //intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);
        
        //final Action otherAction = new IntentAction(this, intent, R.drawable.ic_title_export_default);
        //actionBar.addAction(otherAction);  
        
        
        viewFlow = (ViewFlow) findViewById(R.id.viewflow);
        ViewFlowAdapter adapter = new ViewFlowAdapter(this); //adapter 객체 생성
        viewFlow.setAdapter(adapter); //adapter 설정
        
        TitleFlowIndicator indicator = (TitleFlowIndicator) findViewById(R.id.viewflowindic);
		indicator.setTitleProvider(adapter); // title provider 설정
		viewFlow.setFlowIndicator(indicator); //viewflow 객체에 titleflowindicator 설정.
        
	// 기존  MainActivity 소스  	
        Spinner sp1 = (Spinner)viewFlow.findViewById(R.id.androidui_sp_1);
        Spinner sp2 = (Spinner)viewFlow.findViewById(R.id.androidui_sp_2);
        
        Vector<String> data1 = new Vector<String>();
        Vector<String> data2 = new Vector<String>();
        
        data1.add("2011-12-25");
        data2.add("8:00 am");
        
        ArrayAdapter<String> adapter1 = new ArrayAdapter<String>(
				this,
				android.R.layout.simple_spinner_item,
				data1);

        adapter1.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
		sp1.setAdapter(adapter1);
		
		ArrayAdapter<String> adapter2 = new ArrayAdapter<String>(
				this,
				android.R.layout.simple_spinner_item,
				data2);

		adapter2.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
		sp2.setAdapter(adapter2);
        
		
		// 기존 ListActivity 소스 
		list = (PullToRefreshListView)viewFlow.findViewById(android.R.id.list); //  list의 id값이 android의 list 값이기 때문에 androi.R 을 참조.
		
		mListItems = new LinkedList<String>();
        mListItems.addAll(Arrays.asList(mStrings));
        
        ArrayAdapter<String> listadapter = new ArrayAdapter<String>(this,
                android.R.layout.simple_list_item_1, mListItems);

        list.setAdapter(listadapter);
		
		
		list.setOnRefreshListener(new OnRefreshListener() {
            public void onRefresh() {
                // Do work to refresh the list here.
                new GetDataTask().execute();
            }
        });
    }

	private class GetDataTask extends AsyncTask<Void, Void, String[]> {

        protected String[] doInBackground(Void... params) {
            // Simulates a background job.
            try {
                Thread.sleep(2000);
            } catch (InterruptedException e) {
                ;
            }
            return mStrings;
        }

        protected void onPostExecute(String[] result) {
            mListItems.addFirst("Added after refresh...");

            // Call onRefreshComplete when the list has been refreshed.
            if(list != null) list.onRefreshComplete();

            super.onPostExecute(result);
        }
    }
	
	
	/* If your min SDK version is < 8 you need to trigger the onConfigurationChanged in ViewFlow manually, like this */
	@Override
	public void onConfigurationChanged(Configuration newConfig) {
		if(viewFlow != null) viewFlow.onConfigurationChanged(newConfig);	//Activity 환경설정 변경 
		super.onConfigurationChanged(newConfig);
	}
	
    public static Intent createIntent(Context context) {
        Intent i = new Intent(context, MainActivity.class);
        i.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);
        return i;
    }
    
    private Intent createShareIntent() {
        final Intent intent = new Intent(Intent.ACTION_SEND);
        intent.setType("text/plain");
        intent.putExtra(Intent.EXTRA_TEXT, "Shared from the ActionBar widget.");
        return Intent.createChooser(intent, "Share");
    }
}


실행 결과















기본 뷰에서 보내기 버튼 옆에있는 EditText를 선택하면 키보드가 올라오면서 선택된 EditText가 보이지 않는 버그가 있긴하지만 최종 목표를 달성하였기 때문에 쿨하게 무시하도록 하겠습니다. (나란 남자 이런남자)


여기까지 Android UI 만들기 포스팅이었구요, 무한 테클 및 질문 환영합니다. 감사합니다. 



AndroidUI - 최종.zip






posted by 엡뽀
prev 1 2 3 4 5 next