change new note dialog

now matches parent
This commit is contained in:
aranzaiger 2016-07-01 17:09:38 +03:00
parent e341fe119d
commit a935dc7ef3
12 changed files with 83 additions and 30 deletions

View file

@ -5,7 +5,7 @@
<GradleProjectSettings>
<option name="distributionType" value="LOCAL" />
<option name="externalProjectPath" value="$PROJECT_DIR$" />
<option name="gradleHome" value="$APPLICATION_HOME_DIR$/gradle/gradle-2.10" />
<option name="gradleHome" value="C:\Program Files\Android\Android Studio\gradle\gradle-2.10" />
<option name="modules">
<set>
<option value="$PROJECT_DIR$" />

View file

@ -1,11 +1,12 @@
<component name="libraryTable">
<library name="animated-vector-drawable-23.3.0">
<CLASSES>
<root url="file://$PROJECT_DIR$/app/build/intermediates/exploded-aar/com.android.support/animated-vector-drawable/23.3.0/res" />
<root url="jar://$PROJECT_DIR$/app/build/intermediates/exploded-aar/com.android.support/animated-vector-drawable/23.3.0/jars/classes.jar!/" />
<root url="file://$PROJECT_DIR$/app/build/intermediates/exploded-aar/com.android.support/animated-vector-drawable/23.3.0/res" />
</CLASSES>
<JAVADOC />
<SOURCES>
<root url="jar://$USER_HOME$/AppData/Local/Android/sdk/extras/android/m2repository/com/android/support/animated-vector-drawable/23.3.0/animated-vector-drawable-23.3.0-sources.jar!/" />
<root url="jar://$USER_HOME$/Library/Android/sdk/extras/android/m2repository/com/android/support/animated-vector-drawable/23.3.0/animated-vector-drawable-23.3.0-sources.jar!/" />
<root url="jar:///opt/android-sdk/extras/android/m2repository/com/android/support/animated-vector-drawable/23.3.0/animated-vector-drawable-23.3.0-sources.jar!/" />
</SOURCES>

View file

@ -1,5 +1,8 @@
<component name="libraryTable">
<library name="appcompat-v7-23.3.0">
<ANNOTATIONS>
<root url="jar://$PROJECT_DIR$/app/build/intermediates/exploded-aar/com.android.support/appcompat-v7/23.3.0/annotations.zip!/" />
</ANNOTATIONS>
<CLASSES>
<root url="jar://$PROJECT_DIR$/app/build/intermediates/exploded-aar/com.android.support/appcompat-v7/23.3.0/jars/classes.jar!/" />
<root url="file://$PROJECT_DIR$/app/build/intermediates/exploded-aar/com.android.support/appcompat-v7/23.3.0/res" />

View file

@ -4,11 +4,12 @@
<root url="jar://$PROJECT_DIR$/app/build/intermediates/exploded-aar/com.android.support/design/23.3.0/annotations.zip!/" />
</ANNOTATIONS>
<CLASSES>
<root url="file://$PROJECT_DIR$/app/build/intermediates/exploded-aar/com.android.support/design/23.3.0/res" />
<root url="jar://$PROJECT_DIR$/app/build/intermediates/exploded-aar/com.android.support/design/23.3.0/jars/classes.jar!/" />
<root url="file://$PROJECT_DIR$/app/build/intermediates/exploded-aar/com.android.support/design/23.3.0/res" />
</CLASSES>
<JAVADOC />
<SOURCES>
<root url="jar://$USER_HOME$/AppData/Local/Android/sdk/extras/android/m2repository/com/android/support/design/23.3.0/design-23.3.0-sources.jar!/" />
<root url="jar://$USER_HOME$/Library/Android/sdk/extras/android/m2repository/com/android/support/design/23.3.0/design-23.3.0-sources.jar!/" />
<root url="jar:///opt/android-sdk/extras/android/m2repository/com/android/support/design/23.3.0/design-23.3.0-sources.jar!/" />
</SOURCES>

View file

@ -9,6 +9,7 @@
</CLASSES>
<JAVADOC />
<SOURCES>
<root url="jar://$USER_HOME$/AppData/Local/Android/sdk/extras/android/m2repository/com/android/support/recyclerview-v7/23.3.0/recyclerview-v7-23.3.0-sources.jar!/" />
<root url="jar://$USER_HOME$/Library/Android/sdk/extras/android/m2repository/com/android/support/recyclerview-v7/23.3.0/recyclerview-v7-23.3.0-sources.jar!/" />
<root url="jar:///opt/android-sdk/extras/android/m2repository/com/android/support/recyclerview-v7/23.3.0/recyclerview-v7-23.3.0-sources.jar!/" />
</SOURCES>

View file

@ -1,10 +1,11 @@
<component name="libraryTable">
<library name="support-annotations-23.3.0">
<CLASSES>
<root url="jar://$USER_HOME$/Library/Android/sdk/extras/android/m2repository/com/android/support/support-annotations/23.3.0/support-annotations-23.3.0.jar!/" />
<root url="jar://$USER_HOME$/AppData/Local/Android/sdk/extras/android/m2repository/com/android/support/support-annotations/23.3.0/support-annotations-23.3.0.jar!/" />
</CLASSES>
<JAVADOC />
<SOURCES>
<root url="jar://$USER_HOME$/AppData/Local/Android/sdk/extras/android/m2repository/com/android/support/support-annotations/23.3.0/support-annotations-23.3.0-sources.jar!/" />
<root url="jar://$USER_HOME$/Library/Android/sdk/extras/android/m2repository/com/android/support/support-annotations/23.3.0/support-annotations-23.3.0-sources.jar!/" />
<root url="jar:///opt/android-sdk/extras/android/m2repository/com/android/support/support-annotations/23.3.0/support-annotations-23.3.0-sources.jar!/" />
</SOURCES>

View file

@ -10,6 +10,7 @@
</CLASSES>
<JAVADOC />
<SOURCES>
<root url="jar://$USER_HOME$/AppData/Local/Android/sdk/extras/android/m2repository/com/android/support/support-v4/23.3.0/support-v4-23.3.0-sources.jar!/" />
<root url="jar://$USER_HOME$/Library/Android/sdk/extras/android/m2repository/com/android/support/support-v4/23.3.0/support-v4-23.3.0-sources.jar!/" />
<root url="jar:///opt/android-sdk/extras/android/m2repository/com/android/support/support-v4/23.3.0/support-v4-23.3.0-sources.jar!/" />
</SOURCES>

View file

@ -6,6 +6,7 @@
</CLASSES>
<JAVADOC />
<SOURCES>
<root url="jar://$USER_HOME$/AppData/Local/Android/sdk/extras/android/m2repository/com/android/support/support-vector-drawable/23.3.0/support-vector-drawable-23.3.0-sources.jar!/" />
<root url="jar://$USER_HOME$/Library/Android/sdk/extras/android/m2repository/com/android/support/support-vector-drawable/23.3.0/support-vector-drawable-23.3.0-sources.jar!/" />
<root url="jar:///opt/android-sdk/extras/android/m2repository/com/android/support/support-vector-drawable/23.3.0/support-vector-drawable-23.3.0-sources.jar!/" />
</SOURCES>

View file

@ -1,7 +1,12 @@
package com.android_app.matan.ara.sagi.thesocialnotework;
import android.app.Dialog;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.view.View;
import android.view.WindowManager;
import android.widget.Button;
import android.widget.EditText;
import android.widget.ListView;
import java.util.ArrayList;
@ -10,6 +15,7 @@ import java.util.List;
public class PersonalSpaceActivity extends AppCompatActivity {
protected ListView noteList;
protected Button addBtn;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
@ -27,6 +33,29 @@ public class PersonalSpaceActivity extends AppCompatActivity {
this.noteList = (ListView)findViewById(R.id.ps_list_listview);
noteList.setAdapter(la);
addBtn = (Button) findViewById(R.id.ps_new_note_button);
addBtn.setOnClickListener(new View.OnClickListener() {
public void onClick(View v) {
final Dialog dialog = new Dialog(PersonalSpaceActivity.this);
dialog.setContentView(R.layout.note_view_full);
dialog.setTitle("New Note");
WindowManager.LayoutParams lp = new WindowManager.LayoutParams();
lp.copyFrom(dialog.getWindow().getAttributes());
lp.width = WindowManager.LayoutParams.MATCH_PARENT;
lp.height = WindowManager.LayoutParams.MATCH_PARENT;
// final EditText editText = (EditText) dialog.findViewById(R.id.editText);
// Button btnSave = (Button) dialog.findViewById(R.id.save);
// Button btnCancel = (Button) dialog.findViewById(R.id.cancel);
dialog.setCancelable(false);
dialog.show();
dialog.getWindow().setAttributes(lp);
}
});
}
}

View file

@ -1,25 +1,40 @@
<?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:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:paddingBottom="@dimen/activity_vertical_margin"
android:paddingLeft="@dimen/activity_horizontal_margin"
android:paddingRight="@dimen/activity_horizontal_margin"
android:paddingTop="@dimen/activity_vertical_margin"
tools:context="com.android_app.matan.ara.sagi.thesocialnotework.PersonalSpaceActivity">
<TextView
<LinearLayout
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="0.2"
android:text="Filters and Shit"
android:id="@+id/ps_filters_textview" />
android:orientation="horizontal">
<TextView
android:id="@+id/ps_filters_textview"
android:layout_width="0dp"
android:layout_height="match_parent"
android:text="Filters and Shit"
android:layout_weight="0.8"/>
<Button
android:id="@+id/ps_new_note_button"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:text="+"
android:onClick=""
android:layout_weight="0.2"/>
</LinearLayout>
<ListView
android:id="@+id/ps_list_listview"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="0.8"
android:id="@+id/ps_list_listview" />
android:layout_weight="0.8" />
</LinearLayout>

View file

@ -1,66 +1,66 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical" android:layout_width="match_parent"
android:layout_height="match_parent">
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<FrameLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
>
android:layout_height="wrap_content">
<EditText
android:id="@+id/nvf_note_title"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/note_title"
android:layout_gravity="center_horizontal|top"
android:layout_marginTop="65dp"
android:text="Title"
android:layout_marginLeft="15dp"
android:layout_marginRight="15dp"
android:layout_marginTop="65dp"
android:autoText="false"
android:editable="true"
android:elegantTextHeight="false"
android:autoText="false"
android:maxLines="1"
android:text="Title"
android:textColor="#c5c4c4" />
<TextView
android:id="@+id/nvf_note_full_label"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Note view"
android:id="@+id/note_full_label"
android:layout_gravity="left|top"
android:layout_marginLeft="15dp"
android:layout_marginTop="25dp"
android:layout_marginLeft="15dp" />
android:text="Note view" />
<Switch
android:id="@+id/nvf_note_permission"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="@+id/note_permission"
android:layout_gravity="center_horizontal|top"
android:layout_marginTop="25dp"
android:textOff="Public"
android:textOn="Private" />
<Button
android:id="@+id/nvf_note_submit_btn"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Note Me"
android:id="@+id/note_submit_btn"
android:layout_gravity="right|top"
android:layout_marginRight="15dp"
android:layout_marginTop="15dp"
android:layout_marginRight="15dp" />
android:text="Note Me" />
<EditText
android:id="@+id/nvf_note_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/note_content"
android:layout_gravity="center_horizontal|top"
android:text="Content"
android:layout_marginLeft="15dp"
android:layout_marginRight="15dp"
android:layout_marginTop="100dp"
android:editable="true"
android:textColor="#c5c4c4"
android:layout_marginTop="100dp" />
android:text="Content"
android:textColor="#c5c4c4" />
</FrameLayout>
</LinearLayout>

View file

@ -5,7 +5,7 @@ buildscript {
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:2.1.0'
classpath 'com.android.tools.build:gradle:2.1.2'
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files