안녕하세요.
제가 한페이지짜리 코드를 만들었는데 프로그램이 시작할 경우, 위쪽에서 아래쪽으로 스크롤이 이동하도록
하고 싶은데 제 생각과는 다르게, 프로그램이 시작할 때 맨 아래쪽으로 이동이 되어 있어서, 위쪽 내용을 보려
면 아래에서 위로 스크롤을 올려야 하는 반대의 상황이 이루어졌습니다.
그런데 이 이유를 찾긴 찾았습니다. 아래쪽에 보면, 리니어 레이아웃으로 구성된 비디오뷰 부분에 있어서
비디오뷰를 제거했을 경우에는 이 문제가 일어나지 않는데, 비디오뷰를 넣는 순간, 아래쪽으로 화면이
포커스가 맞춰져서 문제가 됩니다.. 포커스를 주는 방법을 찾아서 검색을 해보았지만, 쉽게 제 소스에
적용을 시키는게 어려워서.. 도움을 얻고자 글을 올립니다.
소스가 xml 파일이다 보니, 조금 넘치는부분이 있어서 아래에 답변에 추가해보겠습니다.
며칠째 원인을 모르겠습니다 ㅠ
아래의 소스 첨부해 보겠습니다.
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/activity_first"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<RelativeLayout
android:id="@+id/CustomAdapterMovie_Toolbar"
android:layout_width="match_parent"
android:layout_height="wrap_content"
>
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"/>
<ImageView
android:id="@+id/Before_Activity"
android:layout_width="wrap_content"
android:layout_toRightOf="@+id/Top_Image_button"
android:paddingTop="10dp"
android:layout_height="wrap_content" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="@+id/Top_Movie_Information"
android:text="상세정보"
android:layout_marginTop="5dp"
android:layout_centerHorizontal="true" />
</RelativeLayout>
<LinearLayout
android:layout_width="match_parent"
android:orientation="horizontal"
android:background="#000000"
android:layout_height="3dp"
></LinearLayout>