master
eazzy 11 months ago committed by SheYu
parent c92b76170f
commit 10f8a7df8e

@ -46,12 +46,28 @@ import java.util.Map;
* @Version: 1.0 * @Version: 1.0
*/ */
public class NoteEditText extends EditText { public class NoteEditText extends EditText {
<<<<<<<< HEAD:src/main/java/net/micode/notes/ui/NoteEditText.java
private static final String TAG = "NoteEditText"; private static final String TAG = "NoteEditText";
private int mIndex; private int mIndex;
private int mSelectionStartBeforeDelete; private int mSelectionStartBeforeDelete;
private static final String SCHEME_TEL = "tel:" ; private static final String SCHEME_TEL = "tel:" ;
private static final String SCHEME_HTTP = "http:" ; private static final String SCHEME_HTTP = "http:" ;
private static final String SCHEME_EMAIL = "mailto:" ; private static final String SCHEME_EMAIL = "mailto:" ;
========
//常量标识
private static final String TAG = "NoteEditText";
//声明整型变量,文本索引
private int mIndex;
//声明整型变量
private int mSelectionStartBeforeDelete;
//声明字符串常量,标志电话、网址、邮件
private static final String SCHEME_TEL = "tel:" ;
private static final String SCHEME_HTTP = "http:" ;
private static final String SCHEME_EMAIL = "mailto:" ;
//设置映射,将文本内容(电话、网址、邮件)做链接处理
>>>>>>>> b654a61 (code):src/Notes/app/src/main/java/net/micode/notes/ui/NoteEditText.java
private static final Map<String, Integer> sSchemaActionResMap = new HashMap<String, Integer>(); private static final Map<String, Integer> sSchemaActionResMap = new HashMap<String, Integer>();
static { static {
sSchemaActionResMap.put(SCHEME_TEL, R.string.note_link_tel); sSchemaActionResMap.put(SCHEME_TEL, R.string.note_link_tel);
@ -96,9 +112,13 @@ public class NoteEditText extends EditText {
mIndex = 0; mIndex = 0;
} }
<<<<<<<< HEAD:src/main/java/net/micode/notes/ui/NoteEditText.java
/** /**
* *
*/ */
========
//设置索引号
>>>>>>>> b654a61 (code):src/Notes/app/src/main/java/net/micode/notes/ui/NoteEditText.java
public void setIndex(int index) { public void setIndex(int index) {
mIndex = index; mIndex = index;
} }
@ -124,6 +144,17 @@ public class NoteEditText extends EditText {
// TODO Auto-generated constructor stub // TODO Auto-generated constructor stub
} }
<<<<<<<< HEAD:src/main/java/net/micode/notes/ui/NoteEditText.java
========
/**
* @method onTouchEvent
* @description
* @date: 12/21/2023 12:41 AM
* @author: YangYizhe
* @param
* @return
*/
>>>>>>>> b654a61 (code):src/Notes/app/src/main/java/net/micode/notes/ui/NoteEditText.java
@Override @Override
/** /**
* @method onTouchEvent * @method onTouchEvent
@ -235,6 +266,17 @@ public class NoteEditText extends EditText {
super.onFocusChanged(focused, direction, previouslyFocusedRect); super.onFocusChanged(focused, direction, previouslyFocusedRect);
} }
<<<<<<<< HEAD:src/main/java/net/micode/notes/ui/NoteEditText.java
========
/**
* @method onCreateContextMenu
* @description
* @date: 12/21/2023 12:39 AM
* @author: YangYizhe
* @param
* @return
*/
>>>>>>>> b654a61 (code):src/Notes/app/src/main/java/net/micode/notes/ui/NoteEditText.java
@Override @Override
/** /**
* @method onCreateContextMenu * @method onCreateContextMenu

Loading…
Cancel
Save