@ -0,0 +1,11 @@
|
|||||||
|
*.iml
|
||||||
|
.gradle
|
||||||
|
/local.properties
|
||||||
|
/.idea/caches/build_file_checksums.ser
|
||||||
|
/.idea/libraries
|
||||||
|
/.idea/modules.xml
|
||||||
|
/.idea/workspace.xml
|
||||||
|
.DS_Store
|
||||||
|
/build
|
||||||
|
/captures
|
||||||
|
.externalNativeBuild
|
@ -0,0 +1,53 @@
|
|||||||
|
<component name="ProjectCodeStyleConfiguration">
|
||||||
|
<code_scheme name="Project" version="173">
|
||||||
|
<Objective-C-extensions>
|
||||||
|
<file>
|
||||||
|
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="Import" />
|
||||||
|
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="Macro" />
|
||||||
|
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="Typedef" />
|
||||||
|
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="Enum" />
|
||||||
|
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="Constant" />
|
||||||
|
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="Global" />
|
||||||
|
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="Struct" />
|
||||||
|
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="FunctionPredecl" />
|
||||||
|
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="Function" />
|
||||||
|
</file>
|
||||||
|
<class>
|
||||||
|
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="Property" />
|
||||||
|
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="Synthesize" />
|
||||||
|
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="InitMethod" />
|
||||||
|
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="StaticMethod" />
|
||||||
|
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="InstanceMethod" />
|
||||||
|
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="DeallocMethod" />
|
||||||
|
</class>
|
||||||
|
<extensions>
|
||||||
|
<pair source="cpp" header="h" fileNamingConvention="NONE" />
|
||||||
|
<pair source="c" header="h" fileNamingConvention="NONE" />
|
||||||
|
</extensions>
|
||||||
|
</Objective-C-extensions>
|
||||||
|
<DBN-PSQL>
|
||||||
|
<case-options enabled="false">
|
||||||
|
<option name="KEYWORD_CASE" value="lower" />
|
||||||
|
<option name="FUNCTION_CASE" value="lower" />
|
||||||
|
<option name="PARAMETER_CASE" value="lower" />
|
||||||
|
<option name="DATATYPE_CASE" value="lower" />
|
||||||
|
<option name="OBJECT_CASE" value="preserve" />
|
||||||
|
</case-options>
|
||||||
|
<formatting-settings enabled="false" />
|
||||||
|
</DBN-PSQL>
|
||||||
|
<DBN-SQL>
|
||||||
|
<case-options enabled="false">
|
||||||
|
<option name="KEYWORD_CASE" value="lower" />
|
||||||
|
<option name="FUNCTION_CASE" value="lower" />
|
||||||
|
<option name="PARAMETER_CASE" value="lower" />
|
||||||
|
<option name="DATATYPE_CASE" value="lower" />
|
||||||
|
<option name="OBJECT_CASE" value="preserve" />
|
||||||
|
</case-options>
|
||||||
|
<formatting-settings enabled="false">
|
||||||
|
<option name="STATEMENT_SPACING" value="one_line" />
|
||||||
|
<option name="CLAUSE_CHOP_DOWN" value="chop_down_if_statement_long" />
|
||||||
|
<option name="ITERATION_ELEMENTS_WRAPPING" value="chop_down_if_not_single" />
|
||||||
|
</formatting-settings>
|
||||||
|
</DBN-SQL>
|
||||||
|
</code_scheme>
|
||||||
|
</component>
|
@ -0,0 +1,453 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="DBNavigator.Project.DataEditorManager">
|
||||||
|
<record-view-column-sorting-type value="BY_INDEX" />
|
||||||
|
<value-preview-text-wrapping value="true" />
|
||||||
|
<value-preview-pinned value="false" />
|
||||||
|
</component>
|
||||||
|
<component name="DBNavigator.Project.DataExportManager">
|
||||||
|
<export-instructions>
|
||||||
|
<create-header value="true" />
|
||||||
|
<quote-values-containing-separator value="true" />
|
||||||
|
<quote-all-values value="false" />
|
||||||
|
<value-separator value="" />
|
||||||
|
<file-name value="" />
|
||||||
|
<file-location value="" />
|
||||||
|
<scope value="GLOBAL" />
|
||||||
|
<destination value="FILE" />
|
||||||
|
<format value="EXCEL" />
|
||||||
|
<charset value="GBK" />
|
||||||
|
</export-instructions>
|
||||||
|
</component>
|
||||||
|
<component name="DBNavigator.Project.DatabaseBrowserManager">
|
||||||
|
<autoscroll-to-editor value="false" />
|
||||||
|
<autoscroll-from-editor value="true" />
|
||||||
|
<show-object-properties value="true" />
|
||||||
|
<loaded-nodes />
|
||||||
|
</component>
|
||||||
|
<component name="DBNavigator.Project.EditorStateManager">
|
||||||
|
<last-used-providers />
|
||||||
|
</component>
|
||||||
|
<component name="DBNavigator.Project.MethodExecutionManager">
|
||||||
|
<method-browser />
|
||||||
|
<execution-history>
|
||||||
|
<group-entries value="true" />
|
||||||
|
<execution-inputs />
|
||||||
|
</execution-history>
|
||||||
|
<argument-values-cache />
|
||||||
|
</component>
|
||||||
|
<component name="DBNavigator.Project.ObjectDependencyManager">
|
||||||
|
<last-used-dependency-type value="INCOMING" />
|
||||||
|
</component>
|
||||||
|
<component name="DBNavigator.Project.ObjectQuickFilterManager">
|
||||||
|
<last-used-operator value="EQUAL" />
|
||||||
|
<filters />
|
||||||
|
</component>
|
||||||
|
<component name="DBNavigator.Project.ScriptExecutionManager" clear-outputs="true">
|
||||||
|
<recently-used-interfaces />
|
||||||
|
</component>
|
||||||
|
<component name="DBNavigator.Project.Settings">
|
||||||
|
<connections />
|
||||||
|
<browser-settings>
|
||||||
|
<general>
|
||||||
|
<display-mode value="TABBED" />
|
||||||
|
<navigation-history-size value="100" />
|
||||||
|
<show-object-details value="false" />
|
||||||
|
</general>
|
||||||
|
<filters>
|
||||||
|
<object-type-filter>
|
||||||
|
<object-type name="SCHEMA" enabled="true" />
|
||||||
|
<object-type name="USER" enabled="true" />
|
||||||
|
<object-type name="ROLE" enabled="true" />
|
||||||
|
<object-type name="PRIVILEGE" enabled="true" />
|
||||||
|
<object-type name="CHARSET" enabled="true" />
|
||||||
|
<object-type name="TABLE" enabled="true" />
|
||||||
|
<object-type name="VIEW" enabled="true" />
|
||||||
|
<object-type name="MATERIALIZED_VIEW" enabled="true" />
|
||||||
|
<object-type name="NESTED_TABLE" enabled="true" />
|
||||||
|
<object-type name="COLUMN" enabled="true" />
|
||||||
|
<object-type name="INDEX" enabled="true" />
|
||||||
|
<object-type name="CONSTRAINT" enabled="true" />
|
||||||
|
<object-type name="DATASET_TRIGGER" enabled="true" />
|
||||||
|
<object-type name="DATABASE_TRIGGER" enabled="true" />
|
||||||
|
<object-type name="SYNONYM" enabled="true" />
|
||||||
|
<object-type name="SEQUENCE" enabled="true" />
|
||||||
|
<object-type name="PROCEDURE" enabled="true" />
|
||||||
|
<object-type name="FUNCTION" enabled="true" />
|
||||||
|
<object-type name="PACKAGE" enabled="true" />
|
||||||
|
<object-type name="TYPE" enabled="true" />
|
||||||
|
<object-type name="TYPE_ATTRIBUTE" enabled="true" />
|
||||||
|
<object-type name="ARGUMENT" enabled="true" />
|
||||||
|
<object-type name="DIMENSION" enabled="true" />
|
||||||
|
<object-type name="CLUSTER" enabled="true" />
|
||||||
|
<object-type name="DBLINK" enabled="true" />
|
||||||
|
</object-type-filter>
|
||||||
|
</filters>
|
||||||
|
<sorting>
|
||||||
|
<object-type name="COLUMN" sorting-type="NAME" />
|
||||||
|
<object-type name="FUNCTION" sorting-type="NAME" />
|
||||||
|
<object-type name="PROCEDURE" sorting-type="NAME" />
|
||||||
|
<object-type name="ARGUMENT" sorting-type="POSITION" />
|
||||||
|
</sorting>
|
||||||
|
<default-editors>
|
||||||
|
<object-type name="VIEW" editor-type="SELECTION" />
|
||||||
|
<object-type name="PACKAGE" editor-type="SELECTION" />
|
||||||
|
<object-type name="TYPE" editor-type="SELECTION" />
|
||||||
|
</default-editors>
|
||||||
|
</browser-settings>
|
||||||
|
<navigation-settings>
|
||||||
|
<lookup-filters>
|
||||||
|
<lookup-objects>
|
||||||
|
<object-type name="SCHEMA" enabled="true" />
|
||||||
|
<object-type name="USER" enabled="false" />
|
||||||
|
<object-type name="ROLE" enabled="false" />
|
||||||
|
<object-type name="PRIVILEGE" enabled="false" />
|
||||||
|
<object-type name="CHARSET" enabled="false" />
|
||||||
|
<object-type name="TABLE" enabled="true" />
|
||||||
|
<object-type name="VIEW" enabled="true" />
|
||||||
|
<object-type name="MATERIALIZED VIEW" enabled="true" />
|
||||||
|
<object-type name="NESTED TABLE" enabled="false" />
|
||||||
|
<object-type name="COLUMN" enabled="false" />
|
||||||
|
<object-type name="INDEX" enabled="true" />
|
||||||
|
<object-type name="CONSTRAINT" enabled="true" />
|
||||||
|
<object-type name="DATASET TRIGGER" enabled="true" />
|
||||||
|
<object-type name="DATABASE TRIGGER" enabled="true" />
|
||||||
|
<object-type name="SYNONYM" enabled="false" />
|
||||||
|
<object-type name="SEQUENCE" enabled="true" />
|
||||||
|
<object-type name="PROCEDURE" enabled="true" />
|
||||||
|
<object-type name="FUNCTION" enabled="true" />
|
||||||
|
<object-type name="PACKAGE" enabled="true" />
|
||||||
|
<object-type name="TYPE" enabled="true" />
|
||||||
|
<object-type name="TYPE ATTRIBUTE" enabled="false" />
|
||||||
|
<object-type name="ARGUMENT" enabled="false" />
|
||||||
|
<object-type name="DIMENSION" enabled="false" />
|
||||||
|
<object-type name="CLUSTER" enabled="false" />
|
||||||
|
<object-type name="DBLINK" enabled="true" />
|
||||||
|
</lookup-objects>
|
||||||
|
<force-database-load value="false" />
|
||||||
|
<prompt-connection-selection value="true" />
|
||||||
|
<prompt-schema-selection value="true" />
|
||||||
|
</lookup-filters>
|
||||||
|
</navigation-settings>
|
||||||
|
<dataset-grid-settings>
|
||||||
|
<general>
|
||||||
|
<enable-zooming value="true" />
|
||||||
|
<enable-column-tooltip value="true" />
|
||||||
|
</general>
|
||||||
|
<sorting>
|
||||||
|
<nulls-first value="true" />
|
||||||
|
<max-sorting-columns value="4" />
|
||||||
|
</sorting>
|
||||||
|
<tracking-columns>
|
||||||
|
<columnNames value="" />
|
||||||
|
<visible value="true" />
|
||||||
|
<editable value="false" />
|
||||||
|
</tracking-columns>
|
||||||
|
</dataset-grid-settings>
|
||||||
|
<dataset-editor-settings>
|
||||||
|
<text-editor-popup>
|
||||||
|
<active value="false" />
|
||||||
|
<active-if-empty value="false" />
|
||||||
|
<data-length-threshold value="100" />
|
||||||
|
<popup-delay value="1000" />
|
||||||
|
</text-editor-popup>
|
||||||
|
<values-list-popup>
|
||||||
|
<show-popup-button value="true" />
|
||||||
|
<element-count-threshold value="1000" />
|
||||||
|
<data-length-threshold value="250" />
|
||||||
|
</values-list-popup>
|
||||||
|
<general>
|
||||||
|
<fetch-block-size value="100" />
|
||||||
|
<fetch-timeout value="30" />
|
||||||
|
<trim-whitespaces value="true" />
|
||||||
|
<convert-empty-strings-to-null value="true" />
|
||||||
|
<select-content-on-cell-edit value="true" />
|
||||||
|
<large-value-preview-active value="true" />
|
||||||
|
</general>
|
||||||
|
<filters>
|
||||||
|
<prompt-filter-dialog value="true" />
|
||||||
|
<default-filter-type value="BASIC" />
|
||||||
|
</filters>
|
||||||
|
<qualified-text-editor text-length-threshold="300">
|
||||||
|
<content-types>
|
||||||
|
<content-type name="Text" enabled="true" />
|
||||||
|
<content-type name="Properties" enabled="true" />
|
||||||
|
<content-type name="XML" enabled="true" />
|
||||||
|
<content-type name="DTD" enabled="true" />
|
||||||
|
<content-type name="HTML" enabled="true" />
|
||||||
|
<content-type name="XHTML" enabled="true" />
|
||||||
|
<content-type name="Java" enabled="true" />
|
||||||
|
<content-type name="SQL" enabled="true" />
|
||||||
|
<content-type name="PL/SQL" enabled="true" />
|
||||||
|
<content-type name="Groovy" enabled="true" />
|
||||||
|
<content-type name="AIDL" enabled="true" />
|
||||||
|
<content-type name="YAML" enabled="true" />
|
||||||
|
<content-type name="Manifest" enabled="true" />
|
||||||
|
</content-types>
|
||||||
|
</qualified-text-editor>
|
||||||
|
<record-navigation>
|
||||||
|
<navigation-target value="VIEWER" />
|
||||||
|
</record-navigation>
|
||||||
|
</dataset-editor-settings>
|
||||||
|
<code-editor-settings>
|
||||||
|
<general>
|
||||||
|
<show-object-navigation-gutter value="false" />
|
||||||
|
<show-spec-declaration-navigation-gutter value="true" />
|
||||||
|
<enable-spellchecking value="true" />
|
||||||
|
<enable-reference-spellchecking value="false" />
|
||||||
|
</general>
|
||||||
|
<confirmations>
|
||||||
|
<save-changes value="false" />
|
||||||
|
<revert-changes value="true" />
|
||||||
|
</confirmations>
|
||||||
|
</code-editor-settings>
|
||||||
|
<code-completion-settings>
|
||||||
|
<filters>
|
||||||
|
<basic-filter>
|
||||||
|
<filter-element type="RESERVED_WORD" id="keyword" selected="true" />
|
||||||
|
<filter-element type="RESERVED_WORD" id="function" selected="true" />
|
||||||
|
<filter-element type="RESERVED_WORD" id="parameter" selected="true" />
|
||||||
|
<filter-element type="RESERVED_WORD" id="datatype" selected="true" />
|
||||||
|
<filter-element type="RESERVED_WORD" id="exception" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="schema" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="role" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="user" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="privilege" selected="true" />
|
||||||
|
<user-schema>
|
||||||
|
<filter-element type="OBJECT" id="table" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="view" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="materialized view" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="index" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="constraint" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="trigger" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="synonym" selected="false" />
|
||||||
|
<filter-element type="OBJECT" id="sequence" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="procedure" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="function" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="package" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="type" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="dimension" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="cluster" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="dblink" selected="true" />
|
||||||
|
</user-schema>
|
||||||
|
<public-schema>
|
||||||
|
<filter-element type="OBJECT" id="table" selected="false" />
|
||||||
|
<filter-element type="OBJECT" id="view" selected="false" />
|
||||||
|
<filter-element type="OBJECT" id="materialized view" selected="false" />
|
||||||
|
<filter-element type="OBJECT" id="index" selected="false" />
|
||||||
|
<filter-element type="OBJECT" id="constraint" selected="false" />
|
||||||
|
<filter-element type="OBJECT" id="trigger" selected="false" />
|
||||||
|
<filter-element type="OBJECT" id="synonym" selected="false" />
|
||||||
|
<filter-element type="OBJECT" id="sequence" selected="false" />
|
||||||
|
<filter-element type="OBJECT" id="procedure" selected="false" />
|
||||||
|
<filter-element type="OBJECT" id="function" selected="false" />
|
||||||
|
<filter-element type="OBJECT" id="package" selected="false" />
|
||||||
|
<filter-element type="OBJECT" id="type" selected="false" />
|
||||||
|
<filter-element type="OBJECT" id="dimension" selected="false" />
|
||||||
|
<filter-element type="OBJECT" id="cluster" selected="false" />
|
||||||
|
<filter-element type="OBJECT" id="dblink" selected="false" />
|
||||||
|
</public-schema>
|
||||||
|
<any-schema>
|
||||||
|
<filter-element type="OBJECT" id="table" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="view" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="materialized view" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="index" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="constraint" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="trigger" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="synonym" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="sequence" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="procedure" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="function" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="package" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="type" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="dimension" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="cluster" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="dblink" selected="true" />
|
||||||
|
</any-schema>
|
||||||
|
</basic-filter>
|
||||||
|
<extended-filter>
|
||||||
|
<filter-element type="RESERVED_WORD" id="keyword" selected="true" />
|
||||||
|
<filter-element type="RESERVED_WORD" id="function" selected="true" />
|
||||||
|
<filter-element type="RESERVED_WORD" id="parameter" selected="true" />
|
||||||
|
<filter-element type="RESERVED_WORD" id="datatype" selected="true" />
|
||||||
|
<filter-element type="RESERVED_WORD" id="exception" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="schema" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="user" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="role" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="privilege" selected="true" />
|
||||||
|
<user-schema>
|
||||||
|
<filter-element type="OBJECT" id="table" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="view" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="materialized view" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="index" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="constraint" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="trigger" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="synonym" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="sequence" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="procedure" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="function" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="package" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="type" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="dimension" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="cluster" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="dblink" selected="true" />
|
||||||
|
</user-schema>
|
||||||
|
<public-schema>
|
||||||
|
<filter-element type="OBJECT" id="table" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="view" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="materialized view" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="index" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="constraint" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="trigger" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="synonym" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="sequence" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="procedure" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="function" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="package" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="type" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="dimension" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="cluster" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="dblink" selected="true" />
|
||||||
|
</public-schema>
|
||||||
|
<any-schema>
|
||||||
|
<filter-element type="OBJECT" id="table" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="view" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="materialized view" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="index" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="constraint" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="trigger" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="synonym" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="sequence" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="procedure" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="function" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="package" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="type" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="dimension" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="cluster" selected="true" />
|
||||||
|
<filter-element type="OBJECT" id="dblink" selected="true" />
|
||||||
|
</any-schema>
|
||||||
|
</extended-filter>
|
||||||
|
</filters>
|
||||||
|
<sorting enabled="true">
|
||||||
|
<sorting-element type="RESERVED_WORD" id="keyword" />
|
||||||
|
<sorting-element type="RESERVED_WORD" id="datatype" />
|
||||||
|
<sorting-element type="OBJECT" id="column" />
|
||||||
|
<sorting-element type="OBJECT" id="table" />
|
||||||
|
<sorting-element type="OBJECT" id="view" />
|
||||||
|
<sorting-element type="OBJECT" id="materialized view" />
|
||||||
|
<sorting-element type="OBJECT" id="index" />
|
||||||
|
<sorting-element type="OBJECT" id="constraint" />
|
||||||
|
<sorting-element type="OBJECT" id="trigger" />
|
||||||
|
<sorting-element type="OBJECT" id="synonym" />
|
||||||
|
<sorting-element type="OBJECT" id="sequence" />
|
||||||
|
<sorting-element type="OBJECT" id="procedure" />
|
||||||
|
<sorting-element type="OBJECT" id="function" />
|
||||||
|
<sorting-element type="OBJECT" id="package" />
|
||||||
|
<sorting-element type="OBJECT" id="type" />
|
||||||
|
<sorting-element type="OBJECT" id="dimension" />
|
||||||
|
<sorting-element type="OBJECT" id="cluster" />
|
||||||
|
<sorting-element type="OBJECT" id="dblink" />
|
||||||
|
<sorting-element type="OBJECT" id="schema" />
|
||||||
|
<sorting-element type="OBJECT" id="role" />
|
||||||
|
<sorting-element type="OBJECT" id="user" />
|
||||||
|
<sorting-element type="RESERVED_WORD" id="function" />
|
||||||
|
<sorting-element type="RESERVED_WORD" id="parameter" />
|
||||||
|
</sorting>
|
||||||
|
<format>
|
||||||
|
<enforce-code-style-case value="true" />
|
||||||
|
</format>
|
||||||
|
</code-completion-settings>
|
||||||
|
<execution-engine-settings>
|
||||||
|
<statement-execution>
|
||||||
|
<fetch-block-size value="100" />
|
||||||
|
<execution-timeout value="20" />
|
||||||
|
<debug-execution-timeout value="600" />
|
||||||
|
<focus-result value="false" />
|
||||||
|
<prompt-execution value="false" />
|
||||||
|
</statement-execution>
|
||||||
|
<script-execution>
|
||||||
|
<command-line-interfaces />
|
||||||
|
<execution-timeout value="300" />
|
||||||
|
</script-execution>
|
||||||
|
<method-execution>
|
||||||
|
<execution-timeout value="30" />
|
||||||
|
<debug-execution-timeout value="600" />
|
||||||
|
<parameter-history-size value="10" />
|
||||||
|
</method-execution>
|
||||||
|
</execution-engine-settings>
|
||||||
|
<operation-settings>
|
||||||
|
<transactions>
|
||||||
|
<uncommitted-changes>
|
||||||
|
<on-project-close value="ASK" />
|
||||||
|
<on-disconnect value="ASK" />
|
||||||
|
<on-autocommit-toggle value="ASK" />
|
||||||
|
</uncommitted-changes>
|
||||||
|
<multiple-uncommitted-changes>
|
||||||
|
<on-commit value="ASK" />
|
||||||
|
<on-rollback value="ASK" />
|
||||||
|
</multiple-uncommitted-changes>
|
||||||
|
</transactions>
|
||||||
|
<session-browser>
|
||||||
|
<disconnect-session value="ASK" />
|
||||||
|
<kill-session value="ASK" />
|
||||||
|
<reload-on-filter-change value="false" />
|
||||||
|
</session-browser>
|
||||||
|
<compiler>
|
||||||
|
<compile-type value="KEEP" />
|
||||||
|
<compile-dependencies value="ASK" />
|
||||||
|
<always-show-controls value="false" />
|
||||||
|
</compiler>
|
||||||
|
<debugger>
|
||||||
|
<debugger-type value="ASK" />
|
||||||
|
<use-generic-runners value="true" />
|
||||||
|
</debugger>
|
||||||
|
</operation-settings>
|
||||||
|
<ddl-file-settings>
|
||||||
|
<extensions>
|
||||||
|
<mapping file-type-id="VIEW" extensions="vw" />
|
||||||
|
<mapping file-type-id="TRIGGER" extensions="trg" />
|
||||||
|
<mapping file-type-id="PROCEDURE" extensions="prc" />
|
||||||
|
<mapping file-type-id="FUNCTION" extensions="fnc" />
|
||||||
|
<mapping file-type-id="PACKAGE" extensions="pkg" />
|
||||||
|
<mapping file-type-id="PACKAGE_SPEC" extensions="pks" />
|
||||||
|
<mapping file-type-id="PACKAGE_BODY" extensions="pkb" />
|
||||||
|
<mapping file-type-id="TYPE" extensions="tpe" />
|
||||||
|
<mapping file-type-id="TYPE_SPEC" extensions="tps" />
|
||||||
|
<mapping file-type-id="TYPE_BODY" extensions="tpb" />
|
||||||
|
</extensions>
|
||||||
|
<general>
|
||||||
|
<lookup-ddl-files value="true" />
|
||||||
|
<create-ddl-files value="false" />
|
||||||
|
<synchronize-ddl-files value="true" />
|
||||||
|
<use-qualified-names value="false" />
|
||||||
|
<make-scripts-rerunnable value="true" />
|
||||||
|
</general>
|
||||||
|
</ddl-file-settings>
|
||||||
|
<general-settings>
|
||||||
|
<regional-settings>
|
||||||
|
<date-format value="MEDIUM" />
|
||||||
|
<number-format value="UNGROUPED" />
|
||||||
|
<locale value="SYSTEM_DEFAULT" />
|
||||||
|
<use-custom-formats value="false" />
|
||||||
|
</regional-settings>
|
||||||
|
<environment>
|
||||||
|
<environment-types>
|
||||||
|
<environment-type id="development" name="Development" description="Development environment" color="-2430209/-12296320" readonly-code="false" readonly-data="false" />
|
||||||
|
<environment-type id="integration" name="Integration" description="Integration environment" color="-2621494/-12163514" readonly-code="true" readonly-data="false" />
|
||||||
|
<environment-type id="production" name="Production" description="Productive environment" color="-11574/-10271420" readonly-code="true" readonly-data="true" />
|
||||||
|
<environment-type id="other" name="Other" description="" color="-1576/-10724543" readonly-code="false" readonly-data="false" />
|
||||||
|
</environment-types>
|
||||||
|
<visibility-settings>
|
||||||
|
<connection-tabs value="true" />
|
||||||
|
<dialog-headers value="true" />
|
||||||
|
<object-editor-tabs value="true" />
|
||||||
|
<script-editor-tabs value="false" />
|
||||||
|
<execution-result-tabs value="true" />
|
||||||
|
</visibility-settings>
|
||||||
|
</environment>
|
||||||
|
</general-settings>
|
||||||
|
</component>
|
||||||
|
<component name="DBNavigator.Project.StatementExecutionManager">
|
||||||
|
<execution-variables />
|
||||||
|
</component>
|
||||||
|
</project>
|
@ -0,0 +1,18 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="GradleSettings">
|
||||||
|
<option name="linkedExternalProjectsSettings">
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="distributionType" value="DEFAULT_WRAPPED" />
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$" />
|
||||||
|
<option value="$PROJECT_DIR$/app" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
<option name="resolveModulePerSourceSet" value="false" />
|
||||||
|
</GradleProjectSettings>
|
||||||
|
</option>
|
||||||
|
</component>
|
||||||
|
</project>
|
@ -0,0 +1,9 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" project-jdk-name="1.8" project-jdk-type="JavaSDK">
|
||||||
|
<output url="file://$PROJECT_DIR$/build/classes" />
|
||||||
|
</component>
|
||||||
|
<component name="ProjectType">
|
||||||
|
<option name="id" value="Android" />
|
||||||
|
</component>
|
||||||
|
</project>
|
@ -0,0 +1,12 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="RunConfigurationProducerService">
|
||||||
|
<option name="ignoredProducers">
|
||||||
|
<set>
|
||||||
|
<option value="org.jetbrains.plugins.gradle.execution.test.runner.AllInPackageGradleConfigurationProducer" />
|
||||||
|
<option value="org.jetbrains.plugins.gradle.execution.test.runner.TestClassGradleConfigurationProducer" />
|
||||||
|
<option value="org.jetbrains.plugins.gradle.execution.test.runner.TestMethodGradleConfigurationProducer" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</component>
|
||||||
|
</project>
|
@ -0,0 +1 @@
|
|||||||
|
/build
|
@ -0,0 +1,21 @@
|
|||||||
|
# Add project specific ProGuard rules here.
|
||||||
|
# You can control the set of applied configuration files using the
|
||||||
|
# proguardFiles setting in build.gradle.
|
||||||
|
#
|
||||||
|
# For more details, see
|
||||||
|
# http://developer.android.com/guide/developing/tools/proguard.html
|
||||||
|
|
||||||
|
# If your project uses WebView with JS, uncomment the following
|
||||||
|
# and specify the fully qualified class name to the JavaScript interface
|
||||||
|
# class:
|
||||||
|
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
|
||||||
|
# public *;
|
||||||
|
#}
|
||||||
|
|
||||||
|
# Uncomment this to preserve the line number information for
|
||||||
|
# debugging stack traces.
|
||||||
|
#-keepattributes SourceFile,LineNumberTable
|
||||||
|
|
||||||
|
# If you keep the line number information, uncomment this to
|
||||||
|
# hide the original source file name.
|
||||||
|
#-renamesourcefileattribute SourceFile
|
@ -0,0 +1,26 @@
|
|||||||
|
package com.example.cici.voice;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
import android.support.test.InstrumentationRegistry;
|
||||||
|
import android.support.test.runner.AndroidJUnit4;
|
||||||
|
|
||||||
|
import org.junit.Test;
|
||||||
|
import org.junit.runner.RunWith;
|
||||||
|
|
||||||
|
import static org.junit.Assert.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Instrumented test, which will execute on an Android device.
|
||||||
|
*
|
||||||
|
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
|
||||||
|
*/
|
||||||
|
@RunWith(AndroidJUnit4.class)
|
||||||
|
public class ExampleInstrumentedTest {
|
||||||
|
@Test
|
||||||
|
public void useAppContext() {
|
||||||
|
// Context of the app under test.
|
||||||
|
Context appContext = InstrumentationRegistry.getTargetContext();
|
||||||
|
|
||||||
|
assertEquals("com.example.cici.voice", appContext.getPackageName());
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,51 @@
|
|||||||
|
package com.example.cici;
|
||||||
|
|
||||||
|
import android.app.Application;
|
||||||
|
import android.content.Context;
|
||||||
|
import android.graphics.Bitmap;
|
||||||
|
import android.widget.ImageView;
|
||||||
|
|
||||||
|
import com.bumptech.glide.Glide;
|
||||||
|
import com.example.cici.utils.ImageLoader;
|
||||||
|
import com.example.cici.voice.R;
|
||||||
|
import com.lzy.imagepicker.ImagePicker;
|
||||||
|
import com.lzy.imagepicker.view.CropImageView;
|
||||||
|
import com.lzy.ninegrid.NineGridView;
|
||||||
|
|
||||||
|
import cn.bmob.v3.Bmob;
|
||||||
|
|
||||||
|
public class MyApplication extends Application {
|
||||||
|
@Override
|
||||||
|
public void onCreate() {
|
||||||
|
super.onCreate();
|
||||||
|
Bmob.initialize(this, "eb215dfb2a8a94afc9c871f4394c3b23");
|
||||||
|
NineGridView.setImageLoader(new GlideImageLoader());
|
||||||
|
ImagePicker imagePicker = ImagePicker.getInstance();
|
||||||
|
imagePicker.setImageLoader(new ImageLoader()); //设置图片加载器
|
||||||
|
imagePicker.setShowCamera(true); //显示拍照按钮
|
||||||
|
imagePicker.setCrop(true); //允许裁剪(单选才有效)
|
||||||
|
imagePicker.setSaveRectangle(true); //是否按矩形区域保存
|
||||||
|
imagePicker.setSelectLimit(9); //选中数量限制
|
||||||
|
imagePicker.setStyle(CropImageView.Style.RECTANGLE); //裁剪框的形状
|
||||||
|
imagePicker.setFocusWidth(800); //裁剪框的宽度。单位像素(圆形自动取宽高最小值)
|
||||||
|
imagePicker.setFocusHeight(800); //裁剪框的高度。单位像素(圆形自动取宽高最小值)
|
||||||
|
imagePicker.setOutPutX(1000);//保存文件的宽度。单位像素
|
||||||
|
imagePicker.setOutPutY(1000);//保存文件的高度。单位像素
|
||||||
|
}
|
||||||
|
private class GlideImageLoader implements NineGridView.ImageLoader {
|
||||||
|
@Override
|
||||||
|
public void onDisplayImage(Context context, ImageView imageView, String url) {
|
||||||
|
Glide.with(context).load(url)//
|
||||||
|
.placeholder(R.drawable.ic_default_image)//
|
||||||
|
.error(R.drawable.ic_default_image)//
|
||||||
|
.into(imageView);
|
||||||
|
|
||||||
|
}
|
||||||
|
@Override
|
||||||
|
public Bitmap getCacheImage(String url) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,79 @@
|
|||||||
|
package com.example.cici.adapter;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
import android.view.LayoutInflater;
|
||||||
|
import android.view.View;
|
||||||
|
import android.view.ViewGroup;
|
||||||
|
import android.widget.BaseAdapter;
|
||||||
|
import android.widget.TextView;
|
||||||
|
|
||||||
|
import com.example.cici.bean.Comment;
|
||||||
|
import com.example.cici.voice.R;
|
||||||
|
import com.makeramen.roundedimageview.RoundedImageView;
|
||||||
|
import com.squareup.picasso.Picasso;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
|
||||||
|
public class CommentAdapter extends BaseAdapter {
|
||||||
|
private ArrayList<Comment> list;
|
||||||
|
private Context context;
|
||||||
|
|
||||||
|
public CommentAdapter(ArrayList<Comment> list, Context context) {
|
||||||
|
this.list = list;
|
||||||
|
this.context = context;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int getCount() {
|
||||||
|
return list.size();
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Object getItem(int i) {
|
||||||
|
return list.get(i);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public long getItemId(int i) {
|
||||||
|
return i;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public View getView(int i, View view, ViewGroup viewGroup) {
|
||||||
|
ViewHolder holder;
|
||||||
|
if (view == null) {
|
||||||
|
view = LayoutInflater.from(context).inflate(R.layout.comm_item, null);
|
||||||
|
holder = new ViewHolder();
|
||||||
|
holder.tvName = (TextView) view.findViewById(R.id.tv_comm_author);
|
||||||
|
holder.head = view.findViewById(R.id.comment_item_icon);
|
||||||
|
holder.tvTime = (TextView) view.findViewById(R.id.comm_time);
|
||||||
|
holder.tvContent = (TextView) view.findViewById(R.id.tv_comm_content);
|
||||||
|
|
||||||
|
view.setTag(holder);
|
||||||
|
} else {
|
||||||
|
holder = (ViewHolder) view.getTag();
|
||||||
|
}
|
||||||
|
final Comment comment=list.get(i);
|
||||||
|
String mycontent = list.get(i).getContent();
|
||||||
|
if (mycontent == null || mycontent.length() <= 0) {
|
||||||
|
holder.tvContent.setVisibility(View.GONE);
|
||||||
|
} else {
|
||||||
|
holder.tvContent.setVisibility(View.VISIBLE);
|
||||||
|
holder.tvContent.setText(mycontent);
|
||||||
|
}
|
||||||
|
holder.tvName.setText(list.get(i).getName());
|
||||||
|
holder.tvTime.setText(list.get(i).getUpdatedAt());
|
||||||
|
Picasso.with(context).load(list.get(i).getUserHead()).into(holder.head);
|
||||||
|
|
||||||
|
return view;
|
||||||
|
}
|
||||||
|
class ViewHolder{
|
||||||
|
TextView tvName;
|
||||||
|
TextView tvContent;
|
||||||
|
TextView tvTime;
|
||||||
|
RoundedImageView head;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,48 @@
|
|||||||
|
package com.example.cici.adapter;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
import android.view.LayoutInflater;
|
||||||
|
import android.view.View;
|
||||||
|
import android.view.ViewGroup;
|
||||||
|
import android.widget.BaseAdapter;
|
||||||
|
import android.widget.TextView;
|
||||||
|
|
||||||
|
import com.example.cici.voice.R;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
|
||||||
|
public class MAdapter extends BaseAdapter {
|
||||||
|
private LayoutInflater inflater;
|
||||||
|
private Context mContext;
|
||||||
|
private ArrayList<String> list;
|
||||||
|
private TextView tv;
|
||||||
|
|
||||||
|
public MAdapter(Context c, ArrayList<String> i) {
|
||||||
|
this.mContext = c;
|
||||||
|
this.list = i;
|
||||||
|
inflater = LayoutInflater.from(c);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int getCount() {
|
||||||
|
return list.size();
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Object getItem(int position) {
|
||||||
|
return list.get(position);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public long getItemId(int position) {
|
||||||
|
return position;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public View getView(int position, View convertView, ViewGroup parent) {
|
||||||
|
convertView = inflater.inflate(R.layout.item, null);
|
||||||
|
tv = (TextView) convertView.findViewById(R.id.tv);
|
||||||
|
tv.setText(list.get(position));
|
||||||
|
return convertView;
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,104 @@
|
|||||||
|
package com.example.cici.adapter;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
import android.view.LayoutInflater;
|
||||||
|
import android.view.View;
|
||||||
|
import android.view.ViewGroup;
|
||||||
|
import android.widget.BaseAdapter;
|
||||||
|
import android.widget.ImageView;
|
||||||
|
import android.widget.TextView;
|
||||||
|
|
||||||
|
|
||||||
|
import com.example.cici.bean.Post;
|
||||||
|
import com.example.cici.voice.R;
|
||||||
|
import com.lzy.ninegrid.ImageInfo;
|
||||||
|
import com.lzy.ninegrid.NineGridView;
|
||||||
|
import com.lzy.ninegrid.preview.NineGridViewClickAdapter;
|
||||||
|
import com.squareup.picasso.Picasso;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
public class MyAdapter extends BaseAdapter {
|
||||||
|
private List<Post> list;
|
||||||
|
private Context context;
|
||||||
|
|
||||||
|
public MyAdapter(Context context, List<Post> list) {
|
||||||
|
this.context = context;
|
||||||
|
this.list = list;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void addPost(List<Post> list) {
|
||||||
|
this.list = list;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int getCount() {
|
||||||
|
if (list == null)
|
||||||
|
return 0;
|
||||||
|
else
|
||||||
|
return list.size();
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Object getItem(int i) {
|
||||||
|
return list.get(i);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public long getItemId(int i) {
|
||||||
|
return i;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public View getView(int i, View view, ViewGroup viewGroup) {
|
||||||
|
ViewHolder holder;
|
||||||
|
if (view == null) {
|
||||||
|
view = LayoutInflater.from(context).inflate(R.layout.item_post, null);
|
||||||
|
holder = new ViewHolder();
|
||||||
|
holder.name = (TextView) view.findViewById(R.id.post_username);
|
||||||
|
holder.time = (TextView) view.findViewById(R.id.post_time);
|
||||||
|
holder.content = (TextView) view.findViewById(R.id.post_content);
|
||||||
|
holder.icon = (ImageView) view.findViewById(R.id.headIcon);
|
||||||
|
holder.nineGrid = (NineGridView) view.findViewById(R.id.post_nineGrid);
|
||||||
|
holder.voice=view.findViewById(R.id.post_voice);
|
||||||
|
view.setTag(holder);
|
||||||
|
} else {
|
||||||
|
holder = (ViewHolder) view.getTag();
|
||||||
|
}
|
||||||
|
Picasso.with(context).load(list.get(i).getUserIcon()).into(holder.icon);
|
||||||
|
String mycontent = list.get(i).getContent();
|
||||||
|
if (mycontent == null || mycontent.length() <= 0) {
|
||||||
|
holder.content.setVisibility(View.GONE);
|
||||||
|
} else {
|
||||||
|
holder.content.setVisibility(View.VISIBLE);
|
||||||
|
holder.content.setText(mycontent);
|
||||||
|
}
|
||||||
|
holder.name.setText(list.get(i).getUserName());
|
||||||
|
holder.voice.setText(list.get(i).getVoiceUrl());
|
||||||
|
holder.time.setText(list.get(i).getTime());
|
||||||
|
if (list.get(i).isHaveIcon()) {//判断是否有图片
|
||||||
|
ArrayList<ImageInfo> imageInfo = new ArrayList<>();
|
||||||
|
for (int j = 0; j < list.get(i).getHeadImgUrl().size(); j++) {
|
||||||
|
ImageInfo info = new ImageInfo();
|
||||||
|
info.setThumbnailUrl(list.get(i).getHeadImgUrl().get(j));
|
||||||
|
info.setBigImageUrl(list.get(i).getHeadImgUrl().get( j));
|
||||||
|
imageInfo.add(info);
|
||||||
|
}
|
||||||
|
holder.nineGrid.setAdapter(new NineGridViewClickAdapter(context, imageInfo));
|
||||||
|
} else {
|
||||||
|
holder.nineGrid.setVisibility(View.GONE);
|
||||||
|
}
|
||||||
|
return view;
|
||||||
|
}
|
||||||
|
|
||||||
|
private class ViewHolder {
|
||||||
|
private TextView name;
|
||||||
|
private TextView time;
|
||||||
|
private TextView content;
|
||||||
|
private ImageView icon;
|
||||||
|
private TextView voice;
|
||||||
|
private com.lzy.ninegrid.NineGridView nineGrid;
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,65 @@
|
|||||||
|
package com.example.cici.bean;
|
||||||
|
|
||||||
|
|
||||||
|
import cn.bmob.v3.BmobObject;
|
||||||
|
|
||||||
|
public class Comment extends BmobObject {
|
||||||
|
/**
|
||||||
|
* 评论内容
|
||||||
|
*/
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
private String content;
|
||||||
|
private User user;
|
||||||
|
private Post post;
|
||||||
|
private String name;
|
||||||
|
private String time;
|
||||||
|
private String userHead;
|
||||||
|
|
||||||
|
public String getUserHead() {
|
||||||
|
return userHead;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setUserHead(String userHead) {
|
||||||
|
this.userHead = userHead;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getTime() {
|
||||||
|
return time;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setTime(String time) {
|
||||||
|
this.time = time;
|
||||||
|
}
|
||||||
|
|
||||||
|
public User getUser() {
|
||||||
|
return user;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setUser(User user) {
|
||||||
|
this.user = user;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Post getPost() {
|
||||||
|
return post;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPost(Post post) {
|
||||||
|
this.post = post;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getName() {
|
||||||
|
return name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setName(String name) {
|
||||||
|
this.name = name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getContent() {
|
||||||
|
return content;
|
||||||
|
}
|
||||||
|
public void setContent(String content) {
|
||||||
|
this.content = content;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,76 @@
|
|||||||
|
package com.example.cici.bean;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import cn.bmob.v3.BmobObject;
|
||||||
|
|
||||||
|
public class Post extends BmobObject {
|
||||||
|
private String userIcon; //头像
|
||||||
|
private String userName; // 名字
|
||||||
|
private String content; // 说说内容
|
||||||
|
private List<String> headImgUrl; //图片的URL集合
|
||||||
|
private String voiceUrl;//录音地址
|
||||||
|
private boolean haveIcon; //判断是否有图片
|
||||||
|
private Integer praise;//点赞
|
||||||
|
private String time;//发表时间
|
||||||
|
|
||||||
|
public String getTime() {
|
||||||
|
return time;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setTime(String time) {
|
||||||
|
this.time = time;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getPraise() {
|
||||||
|
return praise;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPraise(Integer praise) {
|
||||||
|
this.praise = praise;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getUserIcon() {
|
||||||
|
return userIcon;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setUserIcon(String userIcon) {
|
||||||
|
this.userIcon = userIcon;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getUserName() {
|
||||||
|
return userName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setUserName(String userName) {
|
||||||
|
this.userName = userName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getContent() {
|
||||||
|
return content;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setContent(String content) {
|
||||||
|
this.content = content;
|
||||||
|
}
|
||||||
|
|
||||||
|
public List<String> getHeadImgUrl() {
|
||||||
|
return headImgUrl;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setHeadImgUrl(List<String> headImgUrl) {
|
||||||
|
this.headImgUrl = headImgUrl;
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean isHaveIcon() {
|
||||||
|
return haveIcon;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setHaveIcon(boolean haveIcon) {
|
||||||
|
this.haveIcon = haveIcon;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getVoiceUrl() { return voiceUrl; }
|
||||||
|
|
||||||
|
public void setVoiceUrl(String voiceUrl) { this.voiceUrl = voiceUrl; }
|
||||||
|
}
|
@ -0,0 +1,93 @@
|
|||||||
|
package com.example.cici.bean;
|
||||||
|
|
||||||
|
import cn.bmob.v3.BmobUser;
|
||||||
|
import cn.bmob.v3.datatype.BmobFile;
|
||||||
|
import cn.bmob.v3.datatype.BmobRelation;
|
||||||
|
|
||||||
|
public class User extends BmobUser {
|
||||||
|
private BmobRelation collect;
|
||||||
|
private String sex;
|
||||||
|
private String img_url;
|
||||||
|
private BmobFile photo;
|
||||||
|
private BmobRelation myPost;
|
||||||
|
private String head;
|
||||||
|
private String birthday;
|
||||||
|
private String phone;
|
||||||
|
|
||||||
|
|
||||||
|
public User() {
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getHead() {
|
||||||
|
return head;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setHead(String head) {
|
||||||
|
this.head = head;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getImg_url() {
|
||||||
|
return img_url;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setImg_url(String img_url) {
|
||||||
|
this.img_url = img_url;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getSex() {
|
||||||
|
return sex;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setSex(String sex) {
|
||||||
|
this.sex = sex;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public BmobFile getPhoto() {
|
||||||
|
return photo;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPhoto(BmobFile photo) {
|
||||||
|
this.photo = photo;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public BmobRelation getCollect() {
|
||||||
|
return collect;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCollect(BmobRelation collect) {
|
||||||
|
this.collect = collect;
|
||||||
|
}
|
||||||
|
|
||||||
|
public BmobRelation getMyPost() {
|
||||||
|
return myPost;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setMyPost(BmobRelation myPost) {
|
||||||
|
this.myPost = myPost;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
public String getBirthday() {
|
||||||
|
return birthday;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setBirthday(String birthday) {
|
||||||
|
this.birthday = birthday;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getPhone() {
|
||||||
|
return phone;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPhone(String phone) {
|
||||||
|
this.phone = phone;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
@ -0,0 +1,57 @@
|
|||||||
|
package com.example.cici.utils;
|
||||||
|
|
||||||
|
import android.graphics.Bitmap;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Created by Andream on 2017/10/19.
|
||||||
|
* 图片裁剪正方形类
|
||||||
|
*/
|
||||||
|
|
||||||
|
public class CircleTransform {
|
||||||
|
/**
|
||||||
|
* @param bitmap 原图
|
||||||
|
* @param edgeLength 希望得到的正方形部分的边长
|
||||||
|
* @return 缩放截取正中部分后的位图。
|
||||||
|
*/
|
||||||
|
public static Bitmap centerSquareScaleBitmap(Bitmap bitmap, int edgeLength)
|
||||||
|
{
|
||||||
|
if(null == bitmap || edgeLength <= 0)
|
||||||
|
{
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
Bitmap result = bitmap;
|
||||||
|
int widthOrg = bitmap.getWidth();
|
||||||
|
int heightOrg = bitmap.getHeight();
|
||||||
|
|
||||||
|
if(widthOrg > edgeLength && heightOrg > edgeLength)
|
||||||
|
{
|
||||||
|
//压缩到一个最小长度是edgeLength的bitmap
|
||||||
|
int longerEdge = (int)(edgeLength * Math.max(widthOrg, heightOrg) / Math.min(widthOrg, heightOrg));
|
||||||
|
int scaledWidth = widthOrg > heightOrg ? longerEdge : edgeLength;
|
||||||
|
int scaledHeight = widthOrg > heightOrg ? edgeLength : longerEdge;
|
||||||
|
Bitmap scaledBitmap;
|
||||||
|
|
||||||
|
try{
|
||||||
|
scaledBitmap = Bitmap.createScaledBitmap(bitmap, scaledWidth, scaledHeight, true);
|
||||||
|
}
|
||||||
|
catch(Exception e){
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
//从图中截取正中间的正方形部分。
|
||||||
|
int xTopLeft = (scaledWidth - edgeLength) / 2;
|
||||||
|
int yTopLeft = (scaledHeight - edgeLength) / 2;
|
||||||
|
|
||||||
|
try{
|
||||||
|
result = Bitmap.createBitmap(scaledBitmap, xTopLeft, yTopLeft, edgeLength, edgeLength);
|
||||||
|
scaledBitmap.recycle();
|
||||||
|
}
|
||||||
|
catch(Exception e){
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,47 @@
|
|||||||
|
package com.example.cici.utils;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
import android.util.AttributeSet;
|
||||||
|
import android.widget.ScrollView;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Created by Andream on 2017/10/19.
|
||||||
|
* 自定义滑动框
|
||||||
|
*/
|
||||||
|
public class GradScrollView extends ScrollView {
|
||||||
|
|
||||||
|
public interface ScrollViewListener {
|
||||||
|
|
||||||
|
void onScrollChanged(GradScrollView scrollView, int x, int y,
|
||||||
|
int oldx, int oldy);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private ScrollViewListener scrollViewListener = null;
|
||||||
|
|
||||||
|
public GradScrollView(Context context) {
|
||||||
|
super(context);
|
||||||
|
}
|
||||||
|
|
||||||
|
public GradScrollView(Context context, AttributeSet attrs,
|
||||||
|
int defStyle) {
|
||||||
|
super(context, attrs, defStyle);
|
||||||
|
}
|
||||||
|
|
||||||
|
public GradScrollView(Context context, AttributeSet attrs) {
|
||||||
|
super(context, attrs);
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setScrollViewListener(ScrollViewListener scrollViewListener) {
|
||||||
|
this.scrollViewListener = scrollViewListener;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void onScrollChanged(int x, int y, int oldx, int oldy) {
|
||||||
|
super.onScrollChanged(x, y, oldx, oldy);
|
||||||
|
if (scrollViewListener != null) {
|
||||||
|
scrollViewListener.onScrollChanged(this, x, y, oldx, oldy);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,38 @@
|
|||||||
|
package com.example.cici.utils;
|
||||||
|
|
||||||
|
import android.app.Activity;
|
||||||
|
import android.net.Uri;
|
||||||
|
import android.widget.ImageView;
|
||||||
|
|
||||||
|
import com.bumptech.glide.Glide;
|
||||||
|
import com.bumptech.glide.load.engine.DiskCacheStrategy;
|
||||||
|
|
||||||
|
import java.io.File;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Created by Andream on 2017/10/19.
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
public class ImageLoader implements com.lzy.imagepicker.loader.ImageLoader{
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void displayImage(Activity activity, String path, ImageView imageView, int width, int height) {
|
||||||
|
Glide.with(activity) //配置上下文
|
||||||
|
.load(Uri.fromFile(new File(path))) //设置图片路径(fix #8,文件名包含%符号 无法识别和显示)
|
||||||
|
.diskCacheStrategy(DiskCacheStrategy.ALL)//缓存全尺寸
|
||||||
|
.into(imageView);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void displayImagePreview(Activity activity, String path, ImageView imageView, int width, int height) {
|
||||||
|
Glide.with(activity) //配置上下文
|
||||||
|
.load(Uri.fromFile(new File(path))) //设置图片路径(fix #8,文件名包含%符号 无法识别和显示)
|
||||||
|
.diskCacheStrategy(DiskCacheStrategy.ALL)//缓存全尺寸
|
||||||
|
.into(imageView);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void clearMemoryCache() {
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,35 @@
|
|||||||
|
package com.example.cici.utils;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Created by Andream on 2017/10/19.
|
||||||
|
* 自定义listview
|
||||||
|
*/
|
||||||
|
import android.content.Context;
|
||||||
|
import android.util.AttributeSet;
|
||||||
|
import android.widget.ListView;
|
||||||
|
|
||||||
|
public class MyListview extends ListView {
|
||||||
|
|
||||||
|
public MyListview(Context context) {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
super(context);
|
||||||
|
}
|
||||||
|
|
||||||
|
public MyListview(Context context, AttributeSet attrs) {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
super(context, attrs);
|
||||||
|
}
|
||||||
|
|
||||||
|
public MyListview(Context context, AttributeSet attrs, int defStyle) {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
super(context, attrs, defStyle);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
int expandSpec = MeasureSpec.makeMeasureSpec(Integer.MAX_VALUE >> 2,
|
||||||
|
MeasureSpec.AT_MOST);
|
||||||
|
super.onMeasure(widthMeasureSpec, expandSpec);
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,29 @@
|
|||||||
|
package com.example.cici.utils;
|
||||||
|
|
||||||
|
import android.os.CountDownTimer;
|
||||||
|
import android.widget.Button;
|
||||||
|
|
||||||
|
|
||||||
|
public class TimeCountUtil extends CountDownTimer {
|
||||||
|
private Button mButton;
|
||||||
|
|
||||||
|
public TimeCountUtil(Button button, long millisInFuture, long countDownInterval) {
|
||||||
|
super(millisInFuture, countDownInterval);
|
||||||
|
this.mButton = button;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onTick(long millisUntilFinished) {
|
||||||
|
// 按钮不可用
|
||||||
|
mButton.setEnabled(false);
|
||||||
|
String showText = millisUntilFinished / 1000 + "秒后可重新发送";
|
||||||
|
mButton.setText(showText);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onFinish() {
|
||||||
|
// 按钮设置可用
|
||||||
|
mButton.setEnabled(true);
|
||||||
|
mButton.setText("重新获取验证码");
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,433 @@
|
|||||||
|
package com.example.cici.voice;
|
||||||
|
|
||||||
|
import android.content.Context;
|
||||||
|
import android.content.Intent;
|
||||||
|
import android.media.MediaPlayer;
|
||||||
|
import android.support.v7.app.AlertDialog;
|
||||||
|
import android.support.v7.app.AppCompatActivity;
|
||||||
|
import android.os.Bundle;
|
||||||
|
import android.text.TextUtils;
|
||||||
|
import android.view.LayoutInflater;
|
||||||
|
import android.view.View;
|
||||||
|
import android.view.inputmethod.InputMethodManager;
|
||||||
|
import android.widget.Button;
|
||||||
|
import android.widget.EditText;
|
||||||
|
import android.widget.ImageView;
|
||||||
|
import android.widget.LinearLayout;
|
||||||
|
import android.widget.TextView;
|
||||||
|
import android.widget.Toast;
|
||||||
|
|
||||||
|
import com.bumptech.glide.Glide;
|
||||||
|
import com.example.cici.adapter.CommentAdapter;
|
||||||
|
import com.example.cici.bean.Comment;
|
||||||
|
import com.example.cici.bean.Post;
|
||||||
|
import com.example.cici.bean.User;
|
||||||
|
import com.example.cici.utils.MyListview;
|
||||||
|
import com.example.cici.voice.R;
|
||||||
|
import com.lzy.ninegrid.ImageInfo;
|
||||||
|
import com.lzy.ninegrid.NineGridView;
|
||||||
|
import com.lzy.ninegrid.preview.NineGridViewClickAdapter;
|
||||||
|
import com.makeramen.roundedimageview.RoundedImageView;
|
||||||
|
|
||||||
|
import java.text.SimpleDateFormat;
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.Date;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import cn.bmob.v3.BmobQuery;
|
||||||
|
import cn.bmob.v3.BmobUser;
|
||||||
|
import cn.bmob.v3.datatype.BmobPointer;
|
||||||
|
import cn.bmob.v3.exception.BmobException;
|
||||||
|
import cn.bmob.v3.listener.FindListener;
|
||||||
|
import cn.bmob.v3.listener.SaveListener;
|
||||||
|
import cn.bmob.v3.listener.UpdateListener;
|
||||||
|
|
||||||
|
public class CommentActivity extends AppCompatActivity implements View.OnClickListener{
|
||||||
|
private float mFirstY;
|
||||||
|
private float mCurrentY;
|
||||||
|
private int direction;
|
||||||
|
private int mTouchSlop;
|
||||||
|
private ArrayList<Comment> list = new ArrayList();
|
||||||
|
private CommentAdapter adapter;
|
||||||
|
private MyListview listView;
|
||||||
|
RoundedImageView head;
|
||||||
|
private Post post = new Post();
|
||||||
|
TextView tv_name, tv_time, tv_content,tv_good,tv_voice;
|
||||||
|
private NineGridView nineGridView;
|
||||||
|
private Button btn_reply;
|
||||||
|
private EditText repy_content,ed_comm;
|
||||||
|
private User user;
|
||||||
|
private String obj;
|
||||||
|
private AlertDialog al;
|
||||||
|
private ArrayList<String> picList = new ArrayList<>();
|
||||||
|
private LinearLayout ly_opte,area_commit;
|
||||||
|
private ImageView et_reply,back_deal,comm_share,comm_del;//返回
|
||||||
|
private Boolean isHaven;//是否存在图片
|
||||||
|
private String auhthor_url;//帖子作者id
|
||||||
|
private String path;
|
||||||
|
private MediaPlayer mPlayer = null;// 播放器
|
||||||
|
@Override
|
||||||
|
protected void onCreate(Bundle savedInstanceState) {
|
||||||
|
super.onCreate(savedInstanceState);
|
||||||
|
setContentView(R.layout.activity_comment);
|
||||||
|
init();
|
||||||
|
initListener();
|
||||||
|
getUrl();
|
||||||
|
}
|
||||||
|
/*
|
||||||
|
初始化数据
|
||||||
|
*/
|
||||||
|
void init() {
|
||||||
|
|
||||||
|
listView = findViewById(R.id.mylv);
|
||||||
|
tv_name = findViewById(R.id.tv_comment_username);
|
||||||
|
tv_time = findViewById(R.id.tv_comment_time);
|
||||||
|
tv_content = findViewById(R.id.tv_comment_content);
|
||||||
|
tv_good = findViewById(R.id.item_good_comment);
|
||||||
|
head = findViewById(R.id.comment_friend_icon);
|
||||||
|
btn_reply = findViewById(R.id.btn_comm);
|
||||||
|
repy_content = findViewById(R.id.ed_comm);
|
||||||
|
nineGridView = findViewById(R.id.comm_nine);
|
||||||
|
area_commit=findViewById(R.id.area_commit);
|
||||||
|
back_deal=findViewById(R.id.back_deal);
|
||||||
|
et_reply=findViewById(R.id.comm_repy);
|
||||||
|
ly_opte = findViewById(R.id.ly_opte);
|
||||||
|
comm_share=findViewById(R.id.comm_share);
|
||||||
|
comm_del=findViewById(R.id.comm_del);
|
||||||
|
tv_voice=findViewById(R.id.tv_comment_voice);
|
||||||
|
tv_name.setText(getIntent().getStringExtra("username"));
|
||||||
|
tv_time.setText(getIntent().getStringExtra("time"));
|
||||||
|
tv_content.setText(getIntent().getStringExtra("content"));
|
||||||
|
String headurl = getIntent().getStringExtra("head");
|
||||||
|
tv_good.setText(getIntent().getStringExtra("goods"));
|
||||||
|
path=getIntent().getStringExtra("voiceUrl");
|
||||||
|
|
||||||
|
obj = getIntent().getStringExtra("obj");
|
||||||
|
if (getIntent().getStringExtra("isHaven").equals("true")){
|
||||||
|
isHaven=true;
|
||||||
|
}
|
||||||
|
post.setObjectId(obj);
|
||||||
|
Glide.with(CommentActivity.this).load(headurl).into(head);
|
||||||
|
user = BmobUser.getCurrentUser(User.class);
|
||||||
|
|
||||||
|
if (getIntent().getStringArrayListExtra("infoList") == null) {
|
||||||
|
nineGridView.setVisibility(View.GONE);
|
||||||
|
} else {
|
||||||
|
picList = getIntent().getStringArrayListExtra("infoList");
|
||||||
|
initPics(picList);
|
||||||
|
}
|
||||||
|
|
||||||
|
findComments();
|
||||||
|
adapter = new CommentAdapter(list, this);
|
||||||
|
listView.setAdapter(adapter);
|
||||||
|
btn_reply.setOnClickListener(new View.OnClickListener() {
|
||||||
|
@Override
|
||||||
|
public void onClick(View view) {
|
||||||
|
//评论
|
||||||
|
String content = repy_content.getText().toString();
|
||||||
|
publishComment(content);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
}
|
||||||
|
void initListener(){
|
||||||
|
tv_voice.setOnClickListener(new View.OnClickListener() {
|
||||||
|
@Override
|
||||||
|
public void onClick(View view) {
|
||||||
|
if (mPlayer != null) {
|
||||||
|
mPlayer.release();
|
||||||
|
mPlayer = null;
|
||||||
|
}
|
||||||
|
mPlayer = new MediaPlayer();
|
||||||
|
// 播放完毕的监听
|
||||||
|
mPlayer.setOnCompletionListener(new MediaPlayer.OnCompletionListener() {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onCompletion(MediaPlayer mp) {
|
||||||
|
// 播放完毕改变状态,释放资源
|
||||||
|
mPlayer.release();
|
||||||
|
mPlayer = null;
|
||||||
|
//startRecord.setEnabled(true);
|
||||||
|
// startPlay.setEnabled(true);
|
||||||
|
// stopPlay.setEnabled(false);
|
||||||
|
//delete.setEnabled(true);
|
||||||
|
//pausePlay.setEnabled(false);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
try {
|
||||||
|
// 播放所选中的录音
|
||||||
|
mPlayer.setDataSource(path);
|
||||||
|
mPlayer.prepare();
|
||||||
|
mPlayer.start();
|
||||||
|
} catch (Exception e) {
|
||||||
|
// 若出现异常被捕获后,同样要释放掉资源
|
||||||
|
// 否则程序会不稳定,不适合正式项目上使用
|
||||||
|
if (mPlayer != null) {
|
||||||
|
mPlayer.release();
|
||||||
|
mPlayer = null;
|
||||||
|
}
|
||||||
|
toast( "播放失败,可返回重试!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
});
|
||||||
|
et_reply.setOnClickListener(new View.OnClickListener() {
|
||||||
|
@Override
|
||||||
|
public void onClick(View view) {
|
||||||
|
reply2();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
tv_good.setOnClickListener(new View.OnClickListener() {
|
||||||
|
@Override
|
||||||
|
public void onClick(View view) {
|
||||||
|
updates();//点赞
|
||||||
|
}
|
||||||
|
});
|
||||||
|
back_deal.setOnClickListener(new View.OnClickListener() {
|
||||||
|
@Override
|
||||||
|
public void onClick(View view) {
|
||||||
|
CommentActivity.this.finish();//关闭详情页
|
||||||
|
}
|
||||||
|
});
|
||||||
|
comm_share.setOnClickListener(new View.OnClickListener() {
|
||||||
|
@Override
|
||||||
|
public void onClick(View view) {
|
||||||
|
share();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
comm_del.setOnClickListener(new View.OnClickListener() {
|
||||||
|
@Override
|
||||||
|
public void onClick(View view) {
|
||||||
|
//删除帖子
|
||||||
|
del();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
private void toast(String date) {
|
||||||
|
Toast.makeText(this, date, Toast.LENGTH_SHORT).show();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
private void publishComment(String content) {
|
||||||
|
|
||||||
|
if (user == null) {
|
||||||
|
toast("发表评论前请先登陆");
|
||||||
|
return;
|
||||||
|
} else if (TextUtils.isEmpty(content)) {
|
||||||
|
toast("发表评论不能为空");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
showDialog_com();
|
||||||
|
final Comment comment = new Comment();
|
||||||
|
|
||||||
|
comment.setContent(content);
|
||||||
|
comment.setPost(post);
|
||||||
|
comment.setUser(user);
|
||||||
|
comment.setName(user.getUsername());
|
||||||
|
comment.setTime(getTime());
|
||||||
|
comment.setUserHead(user.getHead());
|
||||||
|
comment.save(new SaveListener<String>() {
|
||||||
|
@Override
|
||||||
|
public void done(String s, BmobException e) {
|
||||||
|
if (e == null) {
|
||||||
|
al.dismiss();
|
||||||
|
findComments();
|
||||||
|
toast("评论成功");
|
||||||
|
adapter.notifyDataSetInvalidated();
|
||||||
|
|
||||||
|
repy_content.setText("");
|
||||||
|
} else {
|
||||||
|
toast(e.toString());
|
||||||
|
al.dismiss();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
查询评论
|
||||||
|
*/
|
||||||
|
private void findComments() {
|
||||||
|
showDialog();
|
||||||
|
BmobQuery<Comment> query = new BmobQuery<Comment>();
|
||||||
|
list.clear();
|
||||||
|
Post post = new Post();
|
||||||
|
post.setObjectId(obj);
|
||||||
|
query.addWhereEqualTo("post", new BmobPointer(post));
|
||||||
|
query.include("user,,author,post.author,comment.time,comment.user");
|
||||||
|
query.findObjects(new FindListener<Comment>() {
|
||||||
|
@Override
|
||||||
|
public void done(List<Comment> arg0, BmobException e) {
|
||||||
|
if (e == null) {
|
||||||
|
|
||||||
|
list.addAll(arg0);
|
||||||
|
//com_num = list.size();
|
||||||
|
al.dismiss();
|
||||||
|
adapter.notifyDataSetInvalidated();
|
||||||
|
|
||||||
|
} else {
|
||||||
|
al.dismiss();
|
||||||
|
toast("查询评论失败" + e.toString());
|
||||||
|
adapter.notifyDataSetChanged();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
获取时间
|
||||||
|
*/
|
||||||
|
public String getTime() {
|
||||||
|
SimpleDateFormat formatter = new SimpleDateFormat("yyyy年MM月dd日 hh点");
|
||||||
|
Date curDate = new Date(System.currentTimeMillis());//获取当前时间
|
||||||
|
return formatter.format(curDate);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void showDialog_com() {
|
||||||
|
LayoutInflater inflater = getLayoutInflater();
|
||||||
|
al = new AlertDialog.Builder(this)
|
||||||
|
.setTitle("回复评论中...")
|
||||||
|
.setView(R.layout.dialog_com)
|
||||||
|
.show();
|
||||||
|
|
||||||
|
}
|
||||||
|
/*
|
||||||
|
隐藏输入框
|
||||||
|
*/
|
||||||
|
private void hideSoftInput(){
|
||||||
|
InputMethodManager imm = (InputMethodManager)this.getSystemService(Context.INPUT_METHOD_SERVICE);
|
||||||
|
|
||||||
|
imm.hideSoftInputFromWindow(ed_comm.getWindowToken(), 0);
|
||||||
|
}
|
||||||
|
/*
|
||||||
|
加载帖子图片集合
|
||||||
|
*/
|
||||||
|
public void initPics(List<String> picList) {
|
||||||
|
|
||||||
|
if (picList.size() > 0) {//判断是否有图片
|
||||||
|
ArrayList<ImageInfo> imageInfo = new ArrayList<>();
|
||||||
|
for (int j = 0; j < picList.size(); j++) {
|
||||||
|
ImageInfo info = new ImageInfo();
|
||||||
|
info.setThumbnailUrl(picList.get(j));
|
||||||
|
info.setBigImageUrl(picList.get(j));
|
||||||
|
imageInfo.add(info);
|
||||||
|
}
|
||||||
|
nineGridView.setAdapter(new NineGridViewClickAdapter(CommentActivity.this, imageInfo));
|
||||||
|
} else {
|
||||||
|
nineGridView.setVisibility(View.GONE);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/*
|
||||||
|
弹出输入框
|
||||||
|
*/
|
||||||
|
public void reply2(){
|
||||||
|
repy_content.requestFocus();
|
||||||
|
InputMethodManager imm = (InputMethodManager) repy_content.getContext().getSystemService(Context.INPUT_METHOD_SERVICE);
|
||||||
|
imm.toggleSoftInput(0, InputMethodManager.SHOW_FORCED);
|
||||||
|
}
|
||||||
|
/*
|
||||||
|
删除帖子
|
||||||
|
*/
|
||||||
|
private void del(){
|
||||||
|
Post p = new Post();
|
||||||
|
p.setObjectId(obj);
|
||||||
|
if (this.user.getObjectId().equals(auhthor_url)){
|
||||||
|
p.delete(new UpdateListener() {
|
||||||
|
@Override
|
||||||
|
public void done(BmobException e) {
|
||||||
|
if(e==null){
|
||||||
|
toast("删除成功");
|
||||||
|
CommentActivity.this.finish();
|
||||||
|
}else{
|
||||||
|
toast("失败:"+e.getMessage()+","+e.getErrorCode());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}else {
|
||||||
|
toast("您无权限删除别人发的帖子哦");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
获取帖子作者信息objid
|
||||||
|
*/
|
||||||
|
public void getUrl() {
|
||||||
|
final String[] obj_info = {""};
|
||||||
|
final BmobQuery<BmobUser> query = new BmobQuery<BmobUser>();
|
||||||
|
query.addWhereEqualTo("username", tv_name.getText().toString());
|
||||||
|
query.findObjects(new FindListener<BmobUser>() {
|
||||||
|
@Override
|
||||||
|
public void done(List<BmobUser> list, BmobException e) {
|
||||||
|
al.dismiss();
|
||||||
|
for (BmobUser data : list) {
|
||||||
|
obj_info[0] = data.getObjectId();
|
||||||
|
auhthor_url = obj_info[0];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
});
|
||||||
|
}
|
||||||
|
/*
|
||||||
|
点赞
|
||||||
|
*/
|
||||||
|
public void updates() {
|
||||||
|
Post post = new Post();
|
||||||
|
post.setObjectId(obj);
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
post.increment("praise");
|
||||||
|
//不知道什么原因点赞后图片会显消失,所以标记一下
|
||||||
|
post.setHaveIcon(isHaven);
|
||||||
|
post.update(new UpdateListener() {
|
||||||
|
@Override
|
||||||
|
public void done(BmobException e) {
|
||||||
|
if (e == null) {
|
||||||
|
toast("点赞成功!");
|
||||||
|
|
||||||
|
} else {
|
||||||
|
toast("点赞失败!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
}
|
||||||
|
/*
|
||||||
|
分享
|
||||||
|
*/
|
||||||
|
public void share(){
|
||||||
|
Intent intent=new Intent(Intent.ACTION_SEND);
|
||||||
|
intent.setType("text/*");
|
||||||
|
intent.putExtra(Intent.EXTRA_SUBJECT, "分享");
|
||||||
|
intent.putExtra(Intent.EXTRA_TEXT,tv_content.getText().toString() +"_"+tv_name.getText()+"_ _来自朋友圈");
|
||||||
|
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
|
||||||
|
startActivity(Intent.createChooser(intent, "分享"));
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
加载框
|
||||||
|
*/
|
||||||
|
private void showDialog() {
|
||||||
|
// 首先得到整个View
|
||||||
|
LayoutInflater inflater = getLayoutInflater();
|
||||||
|
al = new AlertDialog.Builder(this)
|
||||||
|
.setCancelable(false)
|
||||||
|
.setTitle("数据装载中...")
|
||||||
|
.setView(R.layout.dialog_com)
|
||||||
|
.setCancelable(true)
|
||||||
|
.show();
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onClick(View view) {
|
||||||
|
switch(view.getId()){
|
||||||
|
case R.id.ed_comm:
|
||||||
|
reply2();
|
||||||
|
break;
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
@ -1,13 +0,0 @@
|
|||||||
package com.example.cici.voice;
|
|
||||||
|
|
||||||
import android.support.v7.app.AppCompatActivity;
|
|
||||||
import android.os.Bundle;
|
|
||||||
|
|
||||||
public class IndexActivity extends AppCompatActivity {
|
|
||||||
|
|
||||||
@Override
|
|
||||||
protected void onCreate(Bundle savedInstanceState) {
|
|
||||||
super.onCreate(savedInstanceState);
|
|
||||||
setContentView(R.layout.activity_index);
|
|
||||||
}
|
|
||||||
}
|
|
@ -0,0 +1,125 @@
|
|||||||
|
package com.example.cici.voice;
|
||||||
|
|
||||||
|
import android.content.Intent;
|
||||||
|
import android.support.v7.app.AppCompatActivity;
|
||||||
|
import android.os.Bundle;
|
||||||
|
import android.view.View;
|
||||||
|
import android.widget.Button;
|
||||||
|
import android.widget.EditText;
|
||||||
|
import android.widget.Toast;
|
||||||
|
|
||||||
|
import com.example.cici.voice.R;
|
||||||
|
import com.example.cici.bean.User;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import cn.bmob.v3.BmobQuery;
|
||||||
|
import cn.bmob.v3.BmobUser;
|
||||||
|
import cn.bmob.v3.exception.BmobException;
|
||||||
|
import cn.bmob.v3.listener.FindListener;
|
||||||
|
import cn.bmob.v3.listener.SaveListener;
|
||||||
|
|
||||||
|
public class LoginActivity extends AppCompatActivity {
|
||||||
|
private EditText log_user,log_pasd;
|
||||||
|
private BmobUser user;
|
||||||
|
private Button btn_log,btn_reg;
|
||||||
|
String name,password;
|
||||||
|
boolean ishave=false;
|
||||||
|
@Override
|
||||||
|
protected void onCreate(Bundle savedInstanceState) {
|
||||||
|
super.onCreate(savedInstanceState);
|
||||||
|
setContentView(R.layout.activity_login);
|
||||||
|
log_user = (EditText) findViewById(R.id.et_username);
|
||||||
|
log_pasd = (EditText) findViewById(R.id.et_pwd);
|
||||||
|
btn_log=findViewById(R.id.btn_login);
|
||||||
|
user=BmobUser.getCurrentUser();
|
||||||
|
if (user!=null){
|
||||||
|
Intent intent = new Intent();
|
||||||
|
intent.setClass(LoginActivity.this, MainActivity.class);
|
||||||
|
startActivity(intent);
|
||||||
|
finish();
|
||||||
|
}
|
||||||
|
btn_log.setOnClickListener(new View.OnClickListener() {
|
||||||
|
@Override
|
||||||
|
public void onClick(View view) {
|
||||||
|
login();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public void toast(String msg) {
|
||||||
|
Toast.makeText(LoginActivity.this, msg, Toast.LENGTH_SHORT).show();
|
||||||
|
}
|
||||||
|
private void login() {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
name=log_user.getText().toString();
|
||||||
|
password=log_pasd.getText().toString();
|
||||||
|
if (name.isEmpty()) {
|
||||||
|
toast("用户名为空");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (password.isEmpty()) {
|
||||||
|
toast("密码为空");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
// isChecked = true;
|
||||||
|
|
||||||
|
|
||||||
|
User user = new User();
|
||||||
|
user.setUsername(name);
|
||||||
|
user.setPassword(password);
|
||||||
|
user.login(new SaveListener<BmobUser>() {
|
||||||
|
@Override
|
||||||
|
public void done(BmobUser bmobUser, BmobException e) {
|
||||||
|
if(e==null){
|
||||||
|
toast("登录成功!");
|
||||||
|
Intent intent = new Intent();
|
||||||
|
intent.setClass(LoginActivity.this, MainActivity.class);
|
||||||
|
startActivity(intent);
|
||||||
|
finish();
|
||||||
|
}else{
|
||||||
|
toast("登录失败! " + e.toString());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
public void OnMyRegistClick(View v) {
|
||||||
|
Intent intent=new Intent(LoginActivity.this,RegisterActivity.class);
|
||||||
|
//intent.putExtra("info", "No66778899");
|
||||||
|
LoginActivity.this.startActivity(intent);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Jump to reset password interface
|
||||||
|
* @param
|
||||||
|
*/
|
||||||
|
/* public void OnMyResPwdClick(View v){
|
||||||
|
Intent intent=new Intent(LoginActivity.this,ResPwdActivity.class);
|
||||||
|
LoginActivity.this.startActivity(intent);
|
||||||
|
}*/
|
||||||
|
|
||||||
|
|
||||||
|
private boolean isHaveUser(String user){
|
||||||
|
|
||||||
|
BmobQuery<BmobUser> query = new BmobQuery<BmobUser>();
|
||||||
|
query.addWhereEqualTo("username", user);
|
||||||
|
query.findObjects(new FindListener<BmobUser>() {
|
||||||
|
@Override
|
||||||
|
public void done(List<BmobUser> object, BmobException e) {
|
||||||
|
if(e==null){
|
||||||
|
toast("查询用户成功:"+object.size());
|
||||||
|
|
||||||
|
ishave=true;
|
||||||
|
}else{
|
||||||
|
toast("查询用户信息失败:" + e.getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
return ishave;
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,103 @@
|
|||||||
|
package com.example.cici.voice;
|
||||||
|
|
||||||
|
import android.app.AlertDialog;
|
||||||
|
import android.content.DialogInterface;
|
||||||
|
import android.content.Intent;
|
||||||
|
import android.os.Bundle;
|
||||||
|
import android.support.v7.app.AppCompatActivity;
|
||||||
|
import android.text.TextUtils;
|
||||||
|
import android.view.View;
|
||||||
|
import android.widget.Button;
|
||||||
|
import android.widget.EditText;
|
||||||
|
import android.widget.Toast;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import cn.bmob.v3.BmobQuery;
|
||||||
|
import cn.bmob.v3.BmobUser;
|
||||||
|
import cn.bmob.v3.exception.BmobException;
|
||||||
|
import cn.bmob.v3.listener.FindListener;
|
||||||
|
|
||||||
|
|
||||||
|
public class ResPwdActivity extends AppCompatActivity {
|
||||||
|
private EditText editUsername;
|
||||||
|
private EditText editPwd;
|
||||||
|
private EditText editResPwd;
|
||||||
|
private String name,password;
|
||||||
|
private Button btnConfirm;
|
||||||
|
boolean ishave=false;
|
||||||
|
public void onCreate(Bundle savedInstanceState) {
|
||||||
|
super.onCreate(savedInstanceState);
|
||||||
|
setContentView(R.layout.res_password);
|
||||||
|
editUsername = findViewById(R.id.editName);
|
||||||
|
editPwd = findViewById(R.id.editPwd);
|
||||||
|
editResPwd = findViewById(R.id.editResPwd);
|
||||||
|
btnConfirm = findViewById(R.id.btnConfirm);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* confirm event
|
||||||
|
* @param v
|
||||||
|
*/
|
||||||
|
public void OnMyConfirmClick(View v) {
|
||||||
|
confirmInfo();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* confirm event
|
||||||
|
*/
|
||||||
|
private void confirmInfo() {
|
||||||
|
name=editUsername.getText().toString();
|
||||||
|
if(TextUtils.isEmpty(editUsername.getText().toString().trim())|| TextUtils.isEmpty(editPwd.getText().toString()) || TextUtils.isEmpty(editResPwd.getText().toString())){
|
||||||
|
Toast.makeText(this, "账号或密码不能为空!", Toast.LENGTH_SHORT).show();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if(!editPwd.getText().toString().equals(editResPwd.getText().toString())) {
|
||||||
|
Toast.makeText(this, "输入密码不正确!", Toast.LENGTH_SHORT).show();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
isHaveUser(name);
|
||||||
|
if(ishave){
|
||||||
|
Toast.makeText(this, "密码重置成功!", Toast.LENGTH_SHORT).show();
|
||||||
|
this.finish();
|
||||||
|
}
|
||||||
|
|
||||||
|
else{
|
||||||
|
new AlertDialog.Builder(this)
|
||||||
|
.setTitle("提示")
|
||||||
|
.setMessage("该用户不存在,请到注册界面进行注册!")
|
||||||
|
.setPositiveButton("确定", new DialogInterface.OnClickListener() {
|
||||||
|
public void onClick(DialogInterface dialog, int whichButton) {
|
||||||
|
setResult(RESULT_OK);
|
||||||
|
Intent intent=new Intent(ResPwdActivity.this,RegisterActivity.class);
|
||||||
|
ResPwdActivity.this.startActivity(intent);
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.setNegativeButton("取消", new DialogInterface.OnClickListener() {
|
||||||
|
public void onClick(DialogInterface dialog, int whichButton) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.show();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
private boolean isHaveUser(String user){
|
||||||
|
|
||||||
|
BmobQuery<BmobUser> query = new BmobQuery<BmobUser>();
|
||||||
|
query.addWhereEqualTo("username", user);
|
||||||
|
query.findObjects(new FindListener<BmobUser>() {
|
||||||
|
@Override
|
||||||
|
public void done(List<BmobUser> object, BmobException e) {
|
||||||
|
if(e==null){
|
||||||
|
|
||||||
|
ishave=true;
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
return ishave;
|
||||||
|
}
|
||||||
|
public void toast(String msg) {
|
||||||
|
Toast.makeText(ResPwdActivity.this, msg, Toast.LENGTH_SHORT).show();
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,34 @@
|
|||||||
|
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:aapt="http://schemas.android.com/aapt"
|
||||||
|
android:width="108dp"
|
||||||
|
android:height="108dp"
|
||||||
|
android:viewportWidth="108"
|
||||||
|
android:viewportHeight="108">
|
||||||
|
<path
|
||||||
|
android:fillType="evenOdd"
|
||||||
|
android:pathData="M32,64C32,64 38.39,52.99 44.13,50.95C51.37,48.37 70.14,49.57 70.14,49.57L108.26,87.69L108,109.01L75.97,107.97L32,64Z"
|
||||||
|
android:strokeWidth="1"
|
||||||
|
android:strokeColor="#00000000">
|
||||||
|
<aapt:attr name="android:fillColor">
|
||||||
|
<gradient
|
||||||
|
android:endX="78.5885"
|
||||||
|
android:endY="90.9159"
|
||||||
|
android:startX="48.7653"
|
||||||
|
android:startY="61.0927"
|
||||||
|
android:type="linear">
|
||||||
|
<item
|
||||||
|
android:color="#44000000"
|
||||||
|
android:offset="0.0" />
|
||||||
|
<item
|
||||||
|
android:color="#00000000"
|
||||||
|
android:offset="1.0" />
|
||||||
|
</gradient>
|
||||||
|
</aapt:attr>
|
||||||
|
</path>
|
||||||
|
<path
|
||||||
|
android:fillColor="#FFFFFF"
|
||||||
|
android:fillType="nonZero"
|
||||||
|
android:pathData="M66.94,46.02L66.94,46.02C72.44,50.07 76,56.61 76,64L32,64C32,56.61 35.56,50.11 40.98,46.06L36.18,41.19C35.45,40.45 35.45,39.3 36.18,38.56C36.91,37.81 38.05,37.81 38.78,38.56L44.25,44.05C47.18,42.57 50.48,41.71 54,41.71C57.48,41.71 60.78,42.57 63.68,44.05L69.11,38.56C69.84,37.81 70.98,37.81 71.71,38.56C72.44,39.3 72.44,40.45 71.71,41.19L66.94,46.02ZM62.94,56.92C64.08,56.92 65,56.01 65,54.88C65,53.76 64.08,52.85 62.94,52.85C61.8,52.85 60.88,53.76 60.88,54.88C60.88,56.01 61.8,56.92 62.94,56.92ZM45.06,56.92C46.2,56.92 47.13,56.01 47.13,54.88C47.13,53.76 46.2,52.85 45.06,52.85C43.92,52.85 43,53.76 43,54.88C43,56.01 43.92,56.92 45.06,56.92Z"
|
||||||
|
android:strokeWidth="1"
|
||||||
|
android:strokeColor="#00000000" />
|
||||||
|
</vector>
|
Before Width: | Height: | Size: 468 KiB |
Before Width: | Height: | Size: 334 KiB |
Before Width: | Height: | Size: 41 KiB |
Before Width: | Height: | Size: 46 KiB |
@ -0,0 +1,170 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
android:width="108dp"
|
||||||
|
android:height="108dp"
|
||||||
|
android:viewportWidth="108"
|
||||||
|
android:viewportHeight="108">
|
||||||
|
<path
|
||||||
|
android:fillColor="#008577"
|
||||||
|
android:pathData="M0,0h108v108h-108z" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M9,0L9,108"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M19,0L19,108"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M29,0L29,108"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M39,0L39,108"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M49,0L49,108"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M59,0L59,108"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M69,0L69,108"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M79,0L79,108"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M89,0L89,108"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M99,0L99,108"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M0,9L108,9"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M0,19L108,19"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M0,29L108,29"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M0,39L108,39"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M0,49L108,49"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M0,59L108,59"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M0,69L108,69"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M0,79L108,79"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M0,89L108,89"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M0,99L108,99"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M19,29L89,29"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M19,39L89,39"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M19,49L89,49"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M19,59L89,59"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M19,69L89,69"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M19,79L89,79"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M29,19L29,89"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M39,19L39,89"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M49,19L49,89"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M59,19L59,89"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M69,19L69,89"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
<path
|
||||||
|
android:fillColor="#00000000"
|
||||||
|
android:pathData="M79,19L79,89"
|
||||||
|
android:strokeWidth="0.8"
|
||||||
|
android:strokeColor="#33FFFFFF" />
|
||||||
|
</vector>
|
Before Width: | Height: | Size: 171 KiB |
Before Width: | Height: | Size: 14 KiB |
Before Width: | Height: | Size: 9.9 KiB |
Before Width: | Height: | Size: 17 KiB |
Before Width: | Height: | Size: 14 KiB |
@ -0,0 +1,241 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:orientation="vertical"
|
||||||
|
>
|
||||||
|
|
||||||
|
|
||||||
|
<include layout="@layout/head" ></include>
|
||||||
|
|
||||||
|
<com.example.cici.utils.GradScrollView
|
||||||
|
android:layout_marginTop="50dp"
|
||||||
|
android:id="@+id/scrollview"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:scrollbars="none"
|
||||||
|
android:layout_alignParentTop="true"
|
||||||
|
android:layout_alignParentLeft="true"
|
||||||
|
android:layout_alignParentStart="true">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:orientation="vertical"
|
||||||
|
android:layout_height="match_parent">
|
||||||
|
|
||||||
|
|
||||||
|
<RelativeLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="100dp">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_comment_time"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_alignBottom="@+id/comment_friend_icon"
|
||||||
|
android:layout_alignStart="@+id/tv_comment_username"
|
||||||
|
android:text="2018:8/1/14:01" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_comment_username"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_alignParentStart="true"
|
||||||
|
android:layout_alignTop="@+id/comment_friend_icon"
|
||||||
|
android:layout_marginStart="104dp"
|
||||||
|
android:text="Ycc"
|
||||||
|
android:textColor="@android:color/holo_red_dark"
|
||||||
|
android:textSize="20sp"
|
||||||
|
android:textStyle="bold" />
|
||||||
|
|
||||||
|
<com.makeramen.roundedimageview.RoundedImageView
|
||||||
|
android:id="@+id/comment_friend_icon"
|
||||||
|
android:layout_width="60dp"
|
||||||
|
android:layout_height="60dp"
|
||||||
|
android:layout_alignParentStart="true"
|
||||||
|
android:layout_centerVertical="true"
|
||||||
|
android:layout_marginStart="16dp"
|
||||||
|
android:src="@mipmap/defhead"
|
||||||
|
app:riv_border_color="@color/colorPrimary"
|
||||||
|
app:riv_border_width="2dip"
|
||||||
|
app:riv_corner_radius="30dip"
|
||||||
|
app:riv_mutate_background="true"
|
||||||
|
app:riv_oval="true"
|
||||||
|
app:riv_tile_mode="clamp" />
|
||||||
|
<View
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:background="#ccc"
|
||||||
|
android:layout_below="@id/tv_comment_time"
|
||||||
|
android:layout_marginTop="3dp"
|
||||||
|
android:layout_height="2dp">
|
||||||
|
|
||||||
|
</View>
|
||||||
|
</RelativeLayout>
|
||||||
|
<LinearLayout
|
||||||
|
android:id="@+id/ly_opte"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:orientation="vertical"
|
||||||
|
android:layout_height="wrap_content">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_comment_content"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:textSize="19sp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginLeft="8dp"
|
||||||
|
android:layout_marginTop="4dp"
|
||||||
|
android:textColor="@android:color/black"
|
||||||
|
android:text="这程序员谁爱当谁当" />
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_comment_voice"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:textSize="19sp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginLeft="8dp"
|
||||||
|
android:layout_marginTop="4dp"
|
||||||
|
android:textColor="@android:color/black"
|
||||||
|
android:text="录音"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<com.lzy.ninegrid.NineGridView
|
||||||
|
android:id="@+id/comm_nine"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginBottom="4dp"
|
||||||
|
android:layout_marginRight="10dp"
|
||||||
|
android:layout_marginLeft="10dp"
|
||||||
|
android:layout_marginTop="5dp"
|
||||||
|
app:ngv_gridSpacing="4dp"
|
||||||
|
app:ngv_maxSize="9"
|
||||||
|
app:ngv_mode="grid"
|
||||||
|
app:ngv_singleImageRatio="1"
|
||||||
|
app:ngv_singleImageSize="150dp" />
|
||||||
|
<LinearLayout
|
||||||
|
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="10dp">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"/>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
|
||||||
|
android:id="@+id/item_good_comment"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:onClick="good"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_alignParentRight="true"
|
||||||
|
android:layout_gravity="center"
|
||||||
|
android:layout_below="@id/tv_comm_content"
|
||||||
|
android:drawableLeft="@mipmap/good_black"
|
||||||
|
android:gravity="center"
|
||||||
|
android:text="156"
|
||||||
|
android:textColor="#888888"
|
||||||
|
android:layout_marginTop="4dip"
|
||||||
|
android:layout_marginBottom="4dip"
|
||||||
|
android:layout_marginLeft="8dip"
|
||||||
|
android:layout_marginRight="8dip"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<RelativeLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/comm_repy"
|
||||||
|
android:layout_width="20dp"
|
||||||
|
android:layout_height="20dp"
|
||||||
|
android:layout_marginTop="5dp"
|
||||||
|
android:layout_alignParentRight="true"
|
||||||
|
android:layout_marginRight="8dp"
|
||||||
|
android:src="@mipmap/say" />
|
||||||
|
</RelativeLayout>
|
||||||
|
|
||||||
|
<RelativeLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:layout_height="wrap_content">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/comm_share"
|
||||||
|
android:layout_width="20dp"
|
||||||
|
android:layout_height="20dp"
|
||||||
|
android:layout_marginTop="5dp"
|
||||||
|
android:layout_alignParentRight="true"
|
||||||
|
android:layout_marginRight="8dp"
|
||||||
|
android:src="@mipmap/shape" />
|
||||||
|
</RelativeLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
<View
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:background="#ccc"
|
||||||
|
android:layout_marginTop="2dp"
|
||||||
|
android:layout_height="1dp">
|
||||||
|
|
||||||
|
</View>
|
||||||
|
|
||||||
|
</LinearLayout><!-- post content end -->
|
||||||
|
<com.example.cici.utils.MyListview
|
||||||
|
android:id="@+id/mylv"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="3dp"
|
||||||
|
android:divider="#dedede"
|
||||||
|
android:dividerHeight="1dp" />
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="45dp">
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</com.example.cici.utils.GradScrollView>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_alignParentBottom="true"
|
||||||
|
android:id="@+id/area_commit"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
|
||||||
|
>
|
||||||
|
|
||||||
|
<EditText
|
||||||
|
android:id="@+id/ed_comm"
|
||||||
|
android:hint="说两句"
|
||||||
|
android:focusable="true"
|
||||||
|
android:focusableInTouchMode="true"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:background="@color/white"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="45dp" />
|
||||||
|
|
||||||
|
<Button
|
||||||
|
android:id="@+id/btn_comm"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="40dp"
|
||||||
|
android:layout_marginRight="0dp"
|
||||||
|
android:background="@android:color/holo_red_dark"
|
||||||
|
android:layout_weight="3"
|
||||||
|
android:onClick="reply"
|
||||||
|
android:padding="3dp"
|
||||||
|
android:text="发表"
|
||||||
|
android:textColor="@color/white" />
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</RelativeLayout>
|
@ -1,125 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
|
||||||
xmlns:tools="http://schemas.android.com/tools"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:background="@drawable/allbackground30">
|
|
||||||
|
|
||||||
<ImageView
|
|
||||||
android:id="@+id/butterflypng"
|
|
||||||
android:layout_width="463dp"
|
|
||||||
android:layout_height="99dp"
|
|
||||||
android:src="@drawable/but"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintHorizontal_bias="0.493"
|
|
||||||
app:layout_constraintStart_toStartOf="parent" />
|
|
||||||
|
|
||||||
<ImageView
|
|
||||||
android:id="@+id/indexdiarypng"
|
|
||||||
android:layout_width="140dp"
|
|
||||||
android:layout_height="140dp"
|
|
||||||
android:layout_marginTop="8dp"
|
|
||||||
android:layout_marginEnd="102dp"
|
|
||||||
android:layout_marginRight="102dp"
|
|
||||||
android:layout_marginBottom="8dp"
|
|
||||||
android:src="@drawable/indexdiary"
|
|
||||||
app:layout_constraintBottom_toTopOf="@+id/butterflypng"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toEndOf="@+id/indexmemotext"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
tools:ignore="MissingConstraints" />
|
|
||||||
|
|
||||||
<ImageView
|
|
||||||
android:id="@+id/indexmyng"
|
|
||||||
android:layout_width="90dp"
|
|
||||||
android:layout_height="90dp"
|
|
||||||
android:layout_marginStart="8dp"
|
|
||||||
android:layout_marginLeft="8dp"
|
|
||||||
android:layout_marginBottom="8dp"
|
|
||||||
android:src="@drawable/indexmy"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
tools:ignore="MissingConstraints" />
|
|
||||||
|
|
||||||
<ImageView
|
|
||||||
android:id="@+id/indexsharepng"
|
|
||||||
android:layout_width="140dp"
|
|
||||||
android:layout_height="140dp"
|
|
||||||
android:layout_marginTop="312dp"
|
|
||||||
android:layout_marginBottom="26dp"
|
|
||||||
android:src="@drawable/indexshare"
|
|
||||||
app:layout_constraintBottom_toTopOf="@+id/butterflypng"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toEndOf="@+id/indexdiarytext"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
tools:ignore="MissingConstraints" />
|
|
||||||
|
|
||||||
<ImageView
|
|
||||||
android:id="@+id/indexmemopng"
|
|
||||||
android:layout_width="140dp"
|
|
||||||
android:layout_height="140dp"
|
|
||||||
android:layout_marginStart="8dp"
|
|
||||||
android:layout_marginLeft="8dp"
|
|
||||||
android:layout_marginTop="8dp"
|
|
||||||
android:src="@drawable/indexmemo"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
tools:ignore="MissingConstraints" />
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:id="@+id/indexmemotext"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginStart="52dp"
|
|
||||||
android:layout_marginLeft="52dp"
|
|
||||||
android:layout_marginTop="157dp"
|
|
||||||
android:layout_marginEnd="30dp"
|
|
||||||
android:layout_marginRight="30dp"
|
|
||||||
android:layout_marginBottom="294dp"
|
|
||||||
android:text="备忘录"
|
|
||||||
android:textColor="#000"
|
|
||||||
android:textSize="20dp"
|
|
||||||
app:layout_constraintBottom_toTopOf="@+id/butterflypng"
|
|
||||||
app:layout_constraintEnd_toEndOf="@+id/indexmemopng"
|
|
||||||
app:layout_constraintEnd_toStartOf="@+id/indexdiarypng"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
|
||||||
tools:ignore="MissingConstraints" />
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:id="@+id/indexdiarytext"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginStart="192dp"
|
|
||||||
android:layout_marginLeft="192dp"
|
|
||||||
android:layout_marginTop="8dp"
|
|
||||||
android:layout_marginEnd="12dp"
|
|
||||||
android:layout_marginRight="12dp"
|
|
||||||
android:text="日记"
|
|
||||||
android:textColor="#000"
|
|
||||||
android:textSize="20dp"
|
|
||||||
app:layout_constraintEnd_toEndOf="@+id/indexdiarypng"
|
|
||||||
app:layout_constraintEnd_toStartOf="@+id/indexsharepng"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toBottomOf="@+id/indexdiarypng"
|
|
||||||
tools:ignore="MissingConstraints" />
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:id="@+id/indexsharetext"
|
|
||||||
android:layout_width="83dp"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginEnd="8dp"
|
|
||||||
android:layout_marginRight="8dp"
|
|
||||||
android:layout_marginBottom="92dp"
|
|
||||||
android:text="分享时刻"
|
|
||||||
android:textColor="#000"
|
|
||||||
android:textSize="20dp"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintEnd_toEndOf="@+id/indexsharepng"
|
|
||||||
app:layout_constraintHorizontal_bias="0.836"
|
|
||||||
app:layout_constraintStart_toStartOf="@+id/indexsharepng"
|
|
||||||
tools:ignore="MissingConstraints" />
|
|
||||||
|
|
||||||
</android.support.constraint.ConstraintLayout>
|
|
@ -0,0 +1,14 @@
|
|||||||
|
<?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:layout_width="match_parent"
|
||||||
|
android:id="@+id/content_main"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:orientation="vertical"
|
||||||
|
tools:context="com.example.cici.voice.MainActivity">
|
||||||
|
|
||||||
|
<include layout="@layout/content_main" />
|
||||||
|
|
||||||
|
|
||||||
|
</LinearLayout>
|
@ -0,0 +1,69 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
>
|
||||||
|
|
||||||
|
<RelativeLayout
|
||||||
|
android:id="@+id/rl_post"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_alignParentStart="true"
|
||||||
|
android:layout_alignParentTop="true">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_comm_author"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_alignParentStart="true"
|
||||||
|
android:layout_alignTop="@+id/comment_item_icon"
|
||||||
|
android:layout_marginStart="66dp"
|
||||||
|
android:text="ycc"
|
||||||
|
|
||||||
|
android:textColor="@android:color/holo_red_dark"
|
||||||
|
android:textSize="15sp" />
|
||||||
|
|
||||||
|
<com.makeramen.roundedimageview.RoundedImageView
|
||||||
|
android:id="@+id/comment_item_icon"
|
||||||
|
android:layout_width="45dp"
|
||||||
|
android:layout_height="45dp"
|
||||||
|
android:layout_marginLeft="10dp"
|
||||||
|
android:layout_marginTop="14dp"
|
||||||
|
android:src="@mipmap/defhead"
|
||||||
|
app:riv_border_color="@color/colorPrimary"
|
||||||
|
app:riv_border_width="2dip"
|
||||||
|
app:riv_corner_radius="30dip"
|
||||||
|
app:riv_mutate_background="true"
|
||||||
|
app:riv_oval="true"
|
||||||
|
app:riv_tile_mode="clamp" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
|
||||||
|
android:id="@+id/tv_comm_content"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_alignParentTop="true"
|
||||||
|
android:layout_alignStart="@+id/tv_comm_author"
|
||||||
|
android:layout_marginTop="40dp"
|
||||||
|
android:text="路飞别做白日梦"
|
||||||
|
android:textColor="@android:color/black"
|
||||||
|
android:textSize="18sp" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/comm_time"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_alignParentRight="true"
|
||||||
|
android:layout_below="@id/tv_comm_content"
|
||||||
|
android:layout_marginRight="3dp"
|
||||||
|
android:layout_marginTop="4dp"
|
||||||
|
|
||||||
|
android:text="一天前"
|
||||||
|
android:layout_marginBottom="3dp"
|
||||||
|
android:textSize="13sp" />
|
||||||
|
</RelativeLayout>
|
||||||
|
|
||||||
|
</RelativeLayout>
|
||||||
|
|
@ -0,0 +1,150 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
|
android:id="@+id/content_main"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
app:layout_behavior="@string/appbar_scrolling_view_behavior"
|
||||||
|
tools:context="com.example.cici.ui.MainActivity"
|
||||||
|
tools:showIn="@layout/activity_main">
|
||||||
|
|
||||||
|
|
||||||
|
<com.example.cici.utils.GradScrollView
|
||||||
|
android:id="@+id/scrollview"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:scrollbars="none"
|
||||||
|
android:layout_alignParentTop="true"
|
||||||
|
android:layout_alignParentLeft="true"
|
||||||
|
android:layout_alignParentStart="true">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:orientation="vertical">
|
||||||
|
|
||||||
|
<RelativeLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="250dp">
|
||||||
|
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/headBkg"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:background="@mipmap/bg"
|
||||||
|
android:scaleType="fitXY" />
|
||||||
|
|
||||||
|
<com.makeramen.roundedimageview.RoundedImageView
|
||||||
|
android:id="@+id/userIcon"
|
||||||
|
android:layout_width="80dp"
|
||||||
|
android:layout_height="80dp"
|
||||||
|
android:layout_marginLeft="20dp"
|
||||||
|
android:layout_marginTop="130dp"
|
||||||
|
app:riv_border_color="@color/colorPrimary"
|
||||||
|
app:riv_border_width="2dip"
|
||||||
|
app:riv_corner_radius="30dip"
|
||||||
|
android:src="@mipmap/defhead"
|
||||||
|
app:riv_mutate_background="true"
|
||||||
|
app:riv_oval="true"
|
||||||
|
app:riv_tile_mode="clamp" />
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:id="@+id/menu_friend"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
|
||||||
|
android:layout_height="30dp"
|
||||||
|
android:layout_alignParentBottom="true">
|
||||||
|
|
||||||
|
<RelativeLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_weight="1">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/TextView"
|
||||||
|
android:text="语音" />
|
||||||
|
</RelativeLayout>
|
||||||
|
|
||||||
|
<RelativeLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_weight="1">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/TextView"
|
||||||
|
android:text="广场" />
|
||||||
|
</RelativeLayout>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<RelativeLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_weight="1">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/TextView"
|
||||||
|
android:text="消息" />
|
||||||
|
</RelativeLayout>
|
||||||
|
|
||||||
|
<RelativeLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_weight="1">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/TextView"
|
||||||
|
android:text="我的" />
|
||||||
|
</RelativeLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</RelativeLayout>
|
||||||
|
|
||||||
|
|
||||||
|
<com.example.cici.utils.MyListview
|
||||||
|
android:id="@+id/lv"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:divider="#dedede"
|
||||||
|
android:dividerHeight="14dp" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
</com.example.cici.utils.GradScrollView>
|
||||||
|
<RelativeLayout
|
||||||
|
android:id="@+id/spaceTopChange"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="55dp"
|
||||||
|
android:background="#003793c7">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/back"
|
||||||
|
android:layout_width="25dp"
|
||||||
|
android:layout_height="25dp"
|
||||||
|
android:layout_centerVertical="true"
|
||||||
|
android:layout_marginLeft="5dp"
|
||||||
|
android:src="@mipmap/left_arrow" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_centerHorizontal="true"
|
||||||
|
android:layout_centerVertical="true"
|
||||||
|
android:text="广场动态"
|
||||||
|
android:textColor="@color/white"
|
||||||
|
android:textSize="17sp" />
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/add"
|
||||||
|
android:layout_width="28dp"
|
||||||
|
android:layout_height="28dp"
|
||||||
|
android:layout_alignParentRight="true"
|
||||||
|
android:layout_centerVertical="true"
|
||||||
|
android:layout_marginRight="10dp"
|
||||||
|
android:src="@mipmap/addpost" />
|
||||||
|
</RelativeLayout>
|
||||||
|
|
||||||
|
</RelativeLayout>
|
@ -0,0 +1,42 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent">
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:text="加载中..."
|
||||||
|
android:textSize="15dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="33dp"
|
||||||
|
android:id="@+id/textView2"
|
||||||
|
android:layout_alignParentTop="true"
|
||||||
|
android:layout_centerHorizontal="true" />
|
||||||
|
|
||||||
|
<ProgressBar
|
||||||
|
android:id="@+id/progressBar"
|
||||||
|
style="?android:attr/progressBarStyle"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_below="@+id/textView2"
|
||||||
|
android:layout_centerHorizontal="true"
|
||||||
|
android:layout_marginTop="14dp" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/textView3"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_below="@+id/progressBar"
|
||||||
|
android:layout_centerHorizontal="true"
|
||||||
|
android:layout_marginTop="21dp"
|
||||||
|
android:text="" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/textView4"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_alignEnd="@+id/textView3"
|
||||||
|
android:layout_below="@+id/textView3"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:text="" />
|
||||||
|
|
||||||
|
</RelativeLayout>
|
@ -0,0 +1,14 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
android:orientation="vertical" android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent">
|
||||||
|
|
||||||
|
<ProgressBar
|
||||||
|
android:id="@+id/progressBar2"
|
||||||
|
style="?android:attr/progressBarStyle"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_alignParentTop="true"
|
||||||
|
android:layout_centerHorizontal="true" />
|
||||||
|
|
||||||
|
</RelativeLayout>
|
@ -0,0 +1,9 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent">
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="80dp"
|
||||||
|
android:id="@+id/gird_img"
|
||||||
|
android:layout_height="80dp" />
|
||||||
|
</LinearLayout>
|
@ -0,0 +1,41 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:background="@color/colorAccent"
|
||||||
|
|
||||||
|
android:layout_height="50dp">
|
||||||
|
<RelativeLayout
|
||||||
|
android:id="@+id/spaceTopChange"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="55dp"
|
||||||
|
android:background="#003793c7">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/comm_del"
|
||||||
|
android:layout_width="25dp"
|
||||||
|
android:layout_height="25dp"
|
||||||
|
android:layout_alignParentEnd="true"
|
||||||
|
android:layout_centerVertical="true"
|
||||||
|
android:layout_marginRight="5dp"
|
||||||
|
app:srcCompat="@mipmap/del" />
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/back_deal"
|
||||||
|
android:layout_width="25dp"
|
||||||
|
android:layout_height="25dp"
|
||||||
|
android:layout_centerVertical="true"
|
||||||
|
android:layout_marginLeft="5dp"
|
||||||
|
android:src="@mipmap/left_arrow" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_centerHorizontal="true"
|
||||||
|
android:layout_centerVertical="true"
|
||||||
|
android:text="详情"
|
||||||
|
android:textColor="@color/white"
|
||||||
|
android:textSize="19sp" />
|
||||||
|
|
||||||
|
</RelativeLayout>
|
||||||
|
</LinearLayout>
|
@ -0,0 +1,16 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:orientation="vertical" >
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:paddingBottom="10dp"
|
||||||
|
android:paddingLeft="10dp"
|
||||||
|
android:paddingRight="10dp"
|
||||||
|
android:textSize="20sp" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
@ -0,0 +1,166 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:orientation="vertical">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="70dp">
|
||||||
|
|
||||||
|
<com.makeramen.roundedimageview.RoundedImageView
|
||||||
|
android:id="@+id/headIcon"
|
||||||
|
android:layout_width="50dp"
|
||||||
|
android:src="@mipmap/defhead"
|
||||||
|
android:layout_height="50dp"
|
||||||
|
android:layout_gravity="center"
|
||||||
|
android:layout_marginLeft="5dp"
|
||||||
|
app:riv_border_color="@color/colorPrimary"
|
||||||
|
app:riv_border_width="2dip"
|
||||||
|
app:riv_corner_radius="30dip"
|
||||||
|
app:riv_mutate_background="true"
|
||||||
|
app:riv_oval="true"
|
||||||
|
app:riv_tile_mode="clamp" />
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_gravity="center"
|
||||||
|
android:layout_marginLeft="10dp"
|
||||||
|
android:orientation="vertical">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/post_username"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="小路飞"
|
||||||
|
android:textColor="@color/text"
|
||||||
|
android:textSize="20sp" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/post_time"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="5dp"
|
||||||
|
android:text="2018/08/01" />
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<RelativeLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_weight="1">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_alignParentRight="true"
|
||||||
|
android:src="@mipmap/down_arrow" />
|
||||||
|
</RelativeLayout>
|
||||||
|
</LinearLayout>
|
||||||
|
<TextView
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:id="@+id/post_content"
|
||||||
|
android:textSize="18sp"
|
||||||
|
|
||||||
|
android:textColor="@color/text"
|
||||||
|
android:layout_marginLeft="17dp"
|
||||||
|
android:layout_height="wrap_content" />
|
||||||
|
<TextView
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:id="@+id/post_voice"
|
||||||
|
android:textSize="18sp"
|
||||||
|
|
||||||
|
android:textColor="@color/text"
|
||||||
|
android:layout_marginLeft="17dp"
|
||||||
|
android:layout_height="wrap_content" />
|
||||||
|
<com.lzy.ninegrid.NineGridView
|
||||||
|
android:id="@+id/post_nineGrid"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginBottom="4dp"
|
||||||
|
android:layout_marginRight="10dp"
|
||||||
|
android:layout_marginLeft="10dp"
|
||||||
|
android:layout_marginTop="5dp"
|
||||||
|
app:ngv_gridSpacing="4dp"
|
||||||
|
app:ngv_maxSize="9"
|
||||||
|
app:ngv_mode="grid"
|
||||||
|
app:ngv_singleImageRatio="1"
|
||||||
|
app:ngv_singleImageSize="250dp" />
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="8dp"
|
||||||
|
android:layout_marginLeft="5dp">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="15dp"
|
||||||
|
android:layout_height="15dp"
|
||||||
|
android:src="@mipmap/phone" />
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="Android" />
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="10dp">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"/>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1">
|
||||||
|
|
||||||
|
<RelativeLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/post_good"
|
||||||
|
android:layout_width="25dp"
|
||||||
|
android:layout_height="25dp"
|
||||||
|
android:layout_alignParentRight="true"
|
||||||
|
android:layout_marginRight="8dp"
|
||||||
|
android:src="@mipmap/good_black" />
|
||||||
|
</RelativeLayout>
|
||||||
|
|
||||||
|
<RelativeLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/post_repy"
|
||||||
|
android:layout_width="25dp"
|
||||||
|
android:layout_height="25dp"
|
||||||
|
android:layout_alignParentRight="true"
|
||||||
|
android:layout_marginRight="8dp"
|
||||||
|
android:src="@mipmap/say" />
|
||||||
|
</RelativeLayout>
|
||||||
|
|
||||||
|
<RelativeLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:layout_height="wrap_content">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/post_share"
|
||||||
|
android:layout_width="25dp"
|
||||||
|
android:layout_height="25dp"
|
||||||
|
android:layout_alignParentRight="true"
|
||||||
|
android:layout_marginRight="8dp"
|
||||||
|
android:src="@mipmap/shape" />
|
||||||
|
</RelativeLayout>
|
||||||
|
</LinearLayout>
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
@ -0,0 +1,127 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
|
||||||
|
android:orientation="vertical"
|
||||||
|
android:layout_height="match_parent">
|
||||||
|
<RelativeLayout
|
||||||
|
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_marginTop="11dp"
|
||||||
|
android:layout_height="50dp">
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_send"
|
||||||
|
android:textStyle="bold"
|
||||||
|
android:textSize="17dp"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_alignParentEnd="true"
|
||||||
|
android:layout_marginRight="7dp"
|
||||||
|
android:textColor="@android:color/holo_green_dark"
|
||||||
|
android:layout_centerVertical="true"
|
||||||
|
android:text="发表" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_cancle"
|
||||||
|
android:textStyle="bold"
|
||||||
|
android:textSize="17dp"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_alignParentStart="true"
|
||||||
|
android:layout_centerVertical="true"
|
||||||
|
android:textColor="@android:color/black"
|
||||||
|
android:layout_marginStart="11dp"
|
||||||
|
android:text="取消" />
|
||||||
|
</RelativeLayout>
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:orientation="vertical">
|
||||||
|
|
||||||
|
<EditText
|
||||||
|
android:id="@+id/et_content"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="60dp"
|
||||||
|
android:layout_margin="10dp"
|
||||||
|
android:layout_marginLeft="20dp"
|
||||||
|
android:background="#00000000"
|
||||||
|
android:hint="这一刻的想法..." />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/playRecord"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="46dp"
|
||||||
|
android:layout_marginStart="57dp"
|
||||||
|
android:layout_marginLeft="20dp"
|
||||||
|
android:layout_marginEnd="19dp"
|
||||||
|
android:layout_marginBottom="0dp"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/time"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="46dp"
|
||||||
|
android:layout_marginStart="57dp"
|
||||||
|
android:layout_marginLeft="20dp"
|
||||||
|
android:layout_marginEnd="19dp"
|
||||||
|
android:layout_marginBottom="0dp"
|
||||||
|
android:text="录音" />
|
||||||
|
|
||||||
|
<GridView
|
||||||
|
android:id="@+id/publishGridView"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="255dp"
|
||||||
|
android:layout_marginLeft="10dp"
|
||||||
|
android:layout_marginTop="4dp"
|
||||||
|
android:layout_marginRight="10dp"
|
||||||
|
android:horizontalSpacing="4dp"
|
||||||
|
android:numColumns="4"
|
||||||
|
android:verticalSpacing="5dp" />
|
||||||
|
</LinearLayout>
|
||||||
|
<RelativeLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content">
|
||||||
|
|
||||||
|
<Button
|
||||||
|
android:id="@+id/startRecord"
|
||||||
|
android:layout_width="86dp"
|
||||||
|
android:layout_height="50dp"
|
||||||
|
android:layout_alignParentBottom="true"
|
||||||
|
android:layout_centerHorizontal="true"
|
||||||
|
android:layout_gravity="center"
|
||||||
|
android:layout_marginTop="141dp"
|
||||||
|
android:layout_marginBottom="84dp"
|
||||||
|
android:text="开始录音"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/resetRecord"
|
||||||
|
android:layout_width="73dp"
|
||||||
|
android:layout_height="46dp"
|
||||||
|
android:layout_alignParentEnd="true"
|
||||||
|
android:layout_alignParentBottom="true"
|
||||||
|
android:layout_gravity="left"
|
||||||
|
android:layout_marginStart="57dp"
|
||||||
|
android:layout_marginEnd="19dp"
|
||||||
|
android:layout_marginBottom="0dp"
|
||||||
|
android:layout_toEndOf="@+id/startRecord"
|
||||||
|
android:text="重录" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/stopRecord"
|
||||||
|
android:layout_width="55dp"
|
||||||
|
android:layout_height="42dp"
|
||||||
|
android:layout_alignParentStart="true"
|
||||||
|
android:layout_alignParentBottom="true"
|
||||||
|
android:layout_gravity="right"
|
||||||
|
android:layout_marginStart="21dp"
|
||||||
|
android:layout_marginEnd="73dp"
|
||||||
|
android:layout_marginBottom="0dp"
|
||||||
|
android:layout_toStartOf="@+id/startRecord"
|
||||||
|
android:text="完成" />
|
||||||
|
</RelativeLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
@ -0,0 +1,90 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
tools:layout_editor_absoluteY="81dp">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/textstyle"
|
||||||
|
android:gravity="center"
|
||||||
|
android:text="@string/login"
|
||||||
|
android:textColor="#ffff"
|
||||||
|
android:textSize="24sp"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintHorizontal_bias="0.0"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
tools:layout_editor_absoluteY="95dp"
|
||||||
|
tools:ignore="MissingConstraints" />
|
||||||
|
<!-- input account -->
|
||||||
|
<EditText
|
||||||
|
android:id="@+id/editPhone"
|
||||||
|
style="@style/textstyle"
|
||||||
|
android:layout_width="fill_parent"
|
||||||
|
android:hint="手机号"
|
||||||
|
android:inputType="number"
|
||||||
|
android:lines="1"
|
||||||
|
android:maxLength="11"
|
||||||
|
android:singleLine="true"
|
||||||
|
tools:layout_editor_absoluteX="5dp"
|
||||||
|
tools:layout_editor_absoluteY="60dp"
|
||||||
|
tools:ignore="MissingConstraints" />
|
||||||
|
<!-- input pwd -->
|
||||||
|
<EditText
|
||||||
|
android:id="@+id/editPwd"
|
||||||
|
style="@style/textstyle"
|
||||||
|
android:layout_width="fill_parent"
|
||||||
|
android:layout_marginTop="36dp"
|
||||||
|
android:layout_marginBottom="8dp"
|
||||||
|
android:hint="密码"
|
||||||
|
android:lines="1"
|
||||||
|
android:maxLength="16"
|
||||||
|
android:password="true"
|
||||||
|
android:singleLine="true"
|
||||||
|
app:layout_constraintBottom_toTopOf="@+id/btnLogin"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintHorizontal_bias="0.545"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toBottomOf="@+id/editPhone" />
|
||||||
|
<!-- the login button -->
|
||||||
|
<Button
|
||||||
|
android:id="@+id/btnLogin"
|
||||||
|
style="@style/textstyle"
|
||||||
|
android:layout_width="fill_parent"
|
||||||
|
android:layout_marginStart="16dp"
|
||||||
|
android:layout_marginBottom="124dp"
|
||||||
|
android:onClick="OnMyLoginClick"
|
||||||
|
android:text="@string/login"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/txtForgetPwd"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginStart="16dp"
|
||||||
|
android:layout_marginBottom="80dp"
|
||||||
|
android:clickable="true"
|
||||||
|
android:onClick="OnMyResPwdClick"
|
||||||
|
android:text="忘记密码"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
tools:ignore="MissingConstraints" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/txtStartRegist"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_alignParentRight="true"
|
||||||
|
android:layout_marginEnd="24dp"
|
||||||
|
android:layout_marginBottom="76dp"
|
||||||
|
android:clickable="true"
|
||||||
|
android:gravity="center"
|
||||||
|
android:onClick="OnMyRegistClick"
|
||||||
|
|
||||||
|
android:text="立即注册"
|
||||||
|
android:textSize="15sp"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent" />
|
||||||
|
</android.support.constraint.ConstraintLayout>
|
@ -0,0 +1,206 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
|
android:orientation="vertical"
|
||||||
|
android:layout_height="match_parent">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<RelativeLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="100dp">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_comment_time"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_alignBottom="@+id/comment_friend_icon"
|
||||||
|
android:layout_alignStart="@+id/tv_comment_username"
|
||||||
|
android:text="2018:8/1/14:01" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_comment_username"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_alignParentStart="true"
|
||||||
|
android:layout_alignTop="@+id/comment_friend_icon"
|
||||||
|
android:layout_marginStart="104dp"
|
||||||
|
android:text="小路飞"
|
||||||
|
android:textColor="@android:color/holo_red_dark"
|
||||||
|
android:textSize="20sp"
|
||||||
|
android:textStyle="bold" />
|
||||||
|
|
||||||
|
<com.makeramen.roundedimageview.RoundedImageView
|
||||||
|
android:id="@+id/comment_friend_icon"
|
||||||
|
android:layout_width="60dp"
|
||||||
|
android:layout_height="60dp"
|
||||||
|
android:layout_alignParentStart="true"
|
||||||
|
android:layout_centerVertical="true"
|
||||||
|
android:layout_marginStart="16dp"
|
||||||
|
android:src="@mipmap/defhead"
|
||||||
|
app:riv_border_color="@color/colorPrimary"
|
||||||
|
app:riv_border_width="2dip"
|
||||||
|
app:riv_corner_radius="30dip"
|
||||||
|
app:riv_mutate_background="true"
|
||||||
|
app:riv_oval="true"
|
||||||
|
app:riv_tile_mode="clamp" />
|
||||||
|
</RelativeLayout>
|
||||||
|
<View
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:background="#ccc"
|
||||||
|
android:layout_marginTop="2dp"
|
||||||
|
android:layout_height="2dp">
|
||||||
|
|
||||||
|
</View>
|
||||||
|
<LinearLayout
|
||||||
|
android:id="@+id/ly_opte"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:orientation="vertical"
|
||||||
|
android:background="#fff"
|
||||||
|
android:layout_height="wrap_content">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_comment_content"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:textSize="19sp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginLeft="8dp"
|
||||||
|
android:layout_marginTop="4dp"
|
||||||
|
android:textColor="@android:color/black"
|
||||||
|
android:text="我是要成为海贼王的人" />
|
||||||
|
voic
|
||||||
|
<com.lzy.ninegrid.NineGridView
|
||||||
|
android:id="@+id/comm_nine"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginBottom="4dp"
|
||||||
|
android:layout_marginRight="10dp"
|
||||||
|
android:layout_marginLeft="10dp"
|
||||||
|
android:layout_marginTop="5dp"
|
||||||
|
app:ngv_gridSpacing="4dp"
|
||||||
|
app:ngv_maxSize="9"
|
||||||
|
app:ngv_mode="grid"
|
||||||
|
app:ngv_singleImageRatio="1"
|
||||||
|
app:ngv_singleImageSize="200dp" />
|
||||||
|
<LinearLayout
|
||||||
|
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="10dp">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"/>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
|
||||||
|
android:id="@+id/item_good_comment"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:onClick="good"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_alignParentRight="true"
|
||||||
|
android:layout_gravity="center"
|
||||||
|
android:layout_below="@id/tv_comm_content"
|
||||||
|
android:drawableLeft="@mipmap/good_black"
|
||||||
|
android:gravity="center"
|
||||||
|
android:text="156"
|
||||||
|
android:textColor="#888888"
|
||||||
|
android:layout_marginTop="4dip"
|
||||||
|
android:layout_marginBottom="4dip"
|
||||||
|
android:layout_marginLeft="8dip"
|
||||||
|
android:layout_marginRight="8dip"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<RelativeLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/comm1_repy"
|
||||||
|
android:layout_width="20dp"
|
||||||
|
android:layout_height="20dp"
|
||||||
|
android:layout_marginTop="5dp"
|
||||||
|
android:layout_alignParentRight="true"
|
||||||
|
android:layout_marginRight="8dp"
|
||||||
|
android:src="@mipmap/say" />
|
||||||
|
</RelativeLayout>
|
||||||
|
|
||||||
|
<RelativeLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:layout_height="wrap_content">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/comm_share1"
|
||||||
|
android:layout_width="20dp"
|
||||||
|
android:layout_height="20dp"
|
||||||
|
android:layout_marginTop="5dp"
|
||||||
|
android:layout_alignParentRight="true"
|
||||||
|
android:layout_marginRight="8dp"
|
||||||
|
android:src="@mipmap/shape" />
|
||||||
|
</RelativeLayout>
|
||||||
|
</LinearLayout>
|
||||||
|
</LinearLayout>
|
||||||
|
<View
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:background="#ccc"
|
||||||
|
android:layout_marginTop="2dp"
|
||||||
|
android:layout_height="1dp">
|
||||||
|
|
||||||
|
</View>
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<RelativeLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content">
|
||||||
|
<ListView
|
||||||
|
android:id="@+id/comment_lv"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
|
||||||
|
android:layout_height="match_parent">
|
||||||
|
|
||||||
|
</ListView>
|
||||||
|
<LinearLayout
|
||||||
|
android:id="@+id/area_commit"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
android:layout_alignParentBottom="true"
|
||||||
|
android:padding="4dip"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
>
|
||||||
|
|
||||||
|
<EditText
|
||||||
|
android:id="@+id/ed_comm"
|
||||||
|
android:hint="说两句"
|
||||||
|
android:focusable="true"
|
||||||
|
android:focusableInTouchMode="true"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:background="@color/white"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="45dp" />
|
||||||
|
|
||||||
|
<Button
|
||||||
|
android:id="@+id/btn_comm"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="40dp"
|
||||||
|
android:layout_marginRight="4dp"
|
||||||
|
android:background="@android:color/holo_red_dark"
|
||||||
|
android:layout_weight="3"
|
||||||
|
android:onClick="reply"
|
||||||
|
android:padding="3dp"
|
||||||
|
android:text="发表"
|
||||||
|
android:textColor="@color/white" />
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</RelativeLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
@ -1,105 +1,76 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
<android.support.constraint.ConstraintLayout
|
||||||
|
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
xmlns:tools="http://schemas.android.com/tools"
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent">
|
||||||
android:background="@drawable/allbackground"
|
|
||||||
tools:layout_editor_absoluteY="25dp">
|
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/textView"
|
android:id="@+id/textView"
|
||||||
style="@style/textstyle"
|
style="@style/textstyle"
|
||||||
android:layout_width="match_parent"
|
android:layout_marginStart="8dp"
|
||||||
android:layout_marginTop="0dp"
|
android:layout_marginEnd="8dp"
|
||||||
android:layout_marginEnd="0dp"
|
|
||||||
android:background="#deffffff"
|
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:text="@string/resPwd"
|
android:text="@string/resPwd"
|
||||||
|
android:textColor="#ffff"
|
||||||
android:textSize="24sp"
|
android:textSize="24sp"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
tools:layout_editor_absoluteY="52dp"
|
||||||
tools:ignore="MissingConstraints" />
|
tools:ignore="MissingConstraints" />
|
||||||
<!-- input phone -->
|
<!-- input phone -->
|
||||||
<EditText
|
<EditText
|
||||||
android:id="@+id/editName"
|
android:id="@+id/editName"
|
||||||
style="@style/textstyle"
|
style="@style/textstyle"
|
||||||
android:layout_width="250dp"
|
android:layout_width="fill_parent"
|
||||||
android:layout_height="50dp"
|
|
||||||
android:layout_marginStart="8dp"
|
|
||||||
android:layout_marginTop="8dp"
|
android:layout_marginTop="8dp"
|
||||||
android:layout_marginEnd="8dp"
|
|
||||||
android:layout_marginBottom="8dp"
|
|
||||||
android:background="#ceefecec"
|
|
||||||
android:hint="请输入用户名"
|
android:hint="请输入用户名"
|
||||||
android:inputType="number"
|
android:inputType="number"
|
||||||
android:lines="1"
|
android:lines="1"
|
||||||
android:maxLength="11"
|
android:maxLength="11"
|
||||||
android:singleLine="true"
|
android:singleLine="true"
|
||||||
app:layout_constraintBottom_toTopOf="@+id/editResPwd"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toBottomOf="@+id/textView"
|
app:layout_constraintTop_toBottomOf="@+id/textView"
|
||||||
tools:ignore="MissingConstraints" />
|
tools:ignore="MissingConstraints"
|
||||||
|
tools:layout_editor_absoluteX="0dp" />
|
||||||
<!-- input password -->
|
<!-- input password -->
|
||||||
<EditText
|
<EditText
|
||||||
android:id="@+id/editPwd"
|
android:id="@+id/editPwd"
|
||||||
style="@style/textstyle"
|
style="@style/textstyle"
|
||||||
android:layout_width="250dp"
|
android:layout_width="fill_parent"
|
||||||
android:layout_height="50dp"
|
|
||||||
android:layout_marginStart="8dp"
|
|
||||||
android:layout_marginTop="8dp"
|
android:layout_marginTop="8dp"
|
||||||
android:layout_marginEnd="8dp"
|
|
||||||
android:layout_marginBottom="8dp"
|
|
||||||
android:background="#ceefecec"
|
|
||||||
android:hint="请输入新密码"
|
android:hint="请输入新密码"
|
||||||
android:lines="1"
|
android:lines="1"
|
||||||
android:maxLength="16"
|
android:maxLength="16"
|
||||||
android:password="true"
|
android:password="true"
|
||||||
android:singleLine="true"
|
android:singleLine="true"
|
||||||
app:layout_constraintBottom_toTopOf="@+id/editResPwd"
|
app:layout_constraintTop_toBottomOf="@+id/editPhone"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
tools:ignore="MissingConstraints"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
tools:layout_editor_absoluteX="0dp" />
|
||||||
app:layout_constraintTop_toBottomOf="@+id/editName"
|
|
||||||
tools:ignore="MissingConstraints" />
|
|
||||||
<!-- input password again -->
|
<!-- input password again -->
|
||||||
<EditText
|
<EditText
|
||||||
android:id="@+id/editResPwd"
|
android:id="@+id/editResPwd"
|
||||||
style="@style/textstyle"
|
style="@style/textstyle"
|
||||||
android:layout_width="250dp"
|
android:layout_width="fill_parent"
|
||||||
android:layout_height="50dp"
|
|
||||||
android:layout_marginStart="8dp"
|
|
||||||
android:layout_marginTop="8dp"
|
android:layout_marginTop="8dp"
|
||||||
android:layout_marginEnd="8dp"
|
|
||||||
android:layout_marginBottom="8dp"
|
|
||||||
android:background="#ceefecec"
|
|
||||||
android:hint="请再次输入新密码"
|
android:hint="请再次输入新密码"
|
||||||
android:lines="1"
|
android:lines="1"
|
||||||
android:maxLength="16"
|
android:maxLength="16"
|
||||||
android:password="true"
|
android:password="true"
|
||||||
android:singleLine="true"
|
android:singleLine="true"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintTop_toBottomOf="@+id/editPwd"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
tools:ignore="MissingConstraints"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
tools:layout_editor_absoluteX="0dp" />
|
||||||
app:layout_constraintTop_toBottomOf="@+id/textView"
|
|
||||||
tools:ignore="MissingConstraints" />
|
|
||||||
<!-- the confirm button -->
|
<!-- the confirm button -->
|
||||||
<Button
|
<Button
|
||||||
android:id="@+id/btnConfirm"
|
android:id="@+id/btnConfirm"
|
||||||
style="@style/textstyle"
|
style="@style/textstyle"
|
||||||
android:layout_width="fill_parent"
|
android:layout_width="fill_parent"
|
||||||
android:layout_height="50dp"
|
android:layout_marginTop="68dp"
|
||||||
android:layout_marginTop="8dp"
|
|
||||||
android:layout_marginBottom="8dp"
|
|
||||||
android:background="#e137b7b5"
|
|
||||||
android:onClick="OnMyConfirmClick"
|
android:onClick="OnMyConfirmClick"
|
||||||
android:text="@string/confirm"
|
android:text="@string/confirm"
|
||||||
android:textColor="#fff"
|
|
||||||
android:textSize="20dp"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
|
||||||
app:layout_constraintTop_toBottomOf="@+id/editResPwd"
|
app:layout_constraintTop_toBottomOf="@+id/editResPwd"
|
||||||
tools:ignore="MissingConstraints"
|
tools:ignore="MissingConstraints"
|
||||||
tools:layout_editor_absoluteX="5dp" />
|
tools:layout_editor_absoluteX="0dp" />
|
||||||
|
|
||||||
</android.support.constraint.ConstraintLayout>
|
</android.support.constraint.ConstraintLayout>
|
@ -0,0 +1,5 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
<background android:drawable="@drawable/ic_launcher_background" />
|
||||||
|
<foreground android:drawable="@drawable/ic_launcher_foreground" />
|
||||||
|
</adaptive-icon>
|
@ -0,0 +1,5 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
<background android:drawable="@drawable/ic_launcher_background" />
|
||||||
|
<foreground android:drawable="@drawable/ic_launcher_foreground" />
|
||||||
|
</adaptive-icon>
|
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 688 B |
After Width: | Height: | Size: 424 B |
After Width: | Height: | Size: 2.1 KiB |
After Width: | Height: | Size: 98 KiB |
After Width: | Height: | Size: 424 KiB |
After Width: | Height: | Size: 6.2 KiB |
After Width: | Height: | Size: 8.1 KiB |
After Width: | Height: | Size: 5.2 KiB |
After Width: | Height: | Size: 2.3 KiB |
After Width: | Height: | Size: 278 B |
After Width: | Height: | Size: 525 B |
After Width: | Height: | Size: 2.2 KiB |
After Width: | Height: | Size: 4.9 KiB |
After Width: | Height: | Size: 6.3 KiB |
After Width: | Height: | Size: 353 B |
After Width: | Height: | Size: 185 B |
After Width: | Height: | Size: 3.4 KiB |
After Width: | Height: | Size: 565 B |
After Width: | Height: | Size: 2.0 KiB |
After Width: | Height: | Size: 2.7 KiB |
After Width: | Height: | Size: 4.4 KiB |
After Width: | Height: | Size: 6.7 KiB |
After Width: | Height: | Size: 6.2 KiB |
After Width: | Height: | Size: 10 KiB |
After Width: | Height: | Size: 8.9 KiB |
After Width: | Height: | Size: 15 KiB |
@ -0,0 +1,8 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<resources>
|
||||||
|
<color name="colorPrimary">#584f60</color>
|
||||||
|
<color name="colorPrimaryDark">#584f60</color>
|
||||||
|
<color name="colorAccent">#584f60</color>
|
||||||
|
<color name="white">#fff</color>
|
||||||
|
<color name="text">#383636</color>
|
||||||
|
</resources>
|
@ -0,0 +1,3 @@
|
|||||||
|
<resources>
|
||||||
|
<dimen name="fab_margin">16dp</dimen>
|
||||||
|
</resources>
|
@ -0,0 +1,33 @@
|
|||||||
|
<resources>
|
||||||
|
|
||||||
|
<!-- Base application theme. -->
|
||||||
|
<style name="AppTheme" parent="Theme.AppCompat.Light.NoActionBar">
|
||||||
|
<!-- Customize your theme here. -->
|
||||||
|
<item name="colorPrimary">@color/colorPrimary</item>
|
||||||
|
<item name="colorPrimaryDark">@color/colorPrimaryDark</item>
|
||||||
|
<item name="colorAccent">@color/colorAccent</item>
|
||||||
|
</style>
|
||||||
|
|
||||||
|
<style name="TextView">
|
||||||
|
<item name="android:layout_width">wrap_content</item>
|
||||||
|
<item name="android:layout_height">wrap_content</item>
|
||||||
|
<item name="android:layout_centerHorizontal">true</item>
|
||||||
|
<item name="android:layout_centerVertical">true</item>
|
||||||
|
<item name="android:layout_gravity">center</item>
|
||||||
|
<item name="android:textColor">@color/white</item>
|
||||||
|
<item name="android:textSize">16sp</item>
|
||||||
|
|
||||||
|
</style>
|
||||||
|
<style name="textstyle">
|
||||||
|
<item name="android:layout_width">fill_parent</item>
|
||||||
|
<item name="android:layout_height">50dp</item>
|
||||||
|
<item name="android:layout_marginLeft">5dp</item>
|
||||||
|
<item name="android:layout_marginRight">5dp</item>
|
||||||
|
<item name="android:layout_marginTop">10dp</item>
|
||||||
|
<item name="android:gravity">center</item>
|
||||||
|
</style>
|
||||||
|
|
||||||
|
<style name="AppTheme.AppBarOverlay" parent="ThemeOverlay.AppCompat.Dark.ActionBar" />
|
||||||
|
|
||||||
|
<style name="AppTheme.PopupOverlay" parent="ThemeOverlay.AppCompat.Light" />
|
||||||
|
</resources>
|
@ -0,0 +1,17 @@
|
|||||||
|
package com.example.cici.voice;
|
||||||
|
|
||||||
|
import org.junit.Test;
|
||||||
|
|
||||||
|
import static org.junit.Assert.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Example local unit test, which will execute on the development machine (host).
|
||||||
|
*
|
||||||
|
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
|
||||||
|
*/
|
||||||
|
public class ExampleUnitTest {
|
||||||
|
@Test
|
||||||
|
public void addition_isCorrect() {
|
||||||
|
assertEquals(4, 2 + 2);
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,29 @@
|
|||||||
|
// Top-level build file where you can add configuration options common to all sub-projects/modules.
|
||||||
|
|
||||||
|
buildscript {
|
||||||
|
|
||||||
|
repositories {
|
||||||
|
google()
|
||||||
|
jcenter()
|
||||||
|
}
|
||||||
|
dependencies {
|
||||||
|
classpath 'com.android.tools.build:gradle:3.2.1'
|
||||||
|
|
||||||
|
|
||||||
|
// NOTE: Do not place your application dependencies here; they belong
|
||||||
|
// in the individual module build.gradle files
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
allprojects {
|
||||||
|
repositories {
|
||||||
|
google()
|
||||||
|
jcenter()
|
||||||
|
maven { url 'https://jitpack.io' }
|
||||||
|
maven { url "https://raw.github.com/bmob/bmob-android-sdk/master" }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
task clean(type: Delete) {
|
||||||
|
delete rootProject.buildDir
|
||||||
|
}
|
@ -0,0 +1,15 @@
|
|||||||
|
# Project-wide Gradle settings.
|
||||||
|
# IDE (e.g. Android Studio) users:
|
||||||
|
# Gradle settings configured through the IDE *will override*
|
||||||
|
# any settings specified in this file.
|
||||||
|
# For more details on how to configure your build environment visit
|
||||||
|
# http://www.gradle.org/docs/current/userguide/build_environment.html
|
||||||
|
# Specifies the JVM arguments used for the daemon process.
|
||||||
|
# The setting is particularly useful for tweaking memory settings.
|
||||||
|
org.gradle.jvmargs=-Xmx1536m
|
||||||
|
# When configured, Gradle will run in incubating parallel mode.
|
||||||
|
# This option should only be used with decoupled projects. More details, visit
|
||||||
|
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
|
||||||
|
# org.gradle.parallel=true
|
||||||
|
|
||||||
|
|