changeset 11:b3cff9bd2cbc

*** empty log message ***
author pin
date Mon, 23 Oct 2006 00:19:15 +0900
parents e40c010c703b
children 4e88130303cc
files bin/remoteeditor/editors/RemoteEditor$1.class bin/remoteeditor/editors/RemoteEditor.class src/remoteeditor/editors/RemoteEditor.java
diffstat 3 files changed, 6 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
Binary file bin/remoteeditor/editors/RemoteEditor$1.class has changed
Binary file bin/remoteeditor/editors/RemoteEditor.class has changed
--- a/src/remoteeditor/editors/RemoteEditor.java	Sun Oct 22 23:28:05 2006 +0900
+++ b/src/remoteeditor/editors/RemoteEditor.java	Mon Oct 23 00:19:15 2006 +0900
@@ -42,7 +42,6 @@
 		super.dispose();
 	}
 	public void textChanged(TextEvent event) {
-		// TODO Auto-generated method stub
 		String replacedText = event.getReplacedText();
 		String inputText = event.getText();
 		
@@ -53,9 +52,14 @@
 		System.out.println("input = " + inputText);
 		
 		try {
+			System.out.println(document.getNumberOfLines(0, textOffset));
+		} catch (BadLocationException e1) {
+			e1.printStackTrace();
+		}
+		
+		try {
 			rep.insert(event.getOffset(), event.getLength(), inputText);
 		} catch (Exception e) {
-			// TODO Auto-generated catch block
 			e.printStackTrace();
 		}
 		
@@ -63,8 +67,6 @@
 
 
 	public void packetReceived(RSocketEvent evt) {
-		// TODO Auto-generated method stub
-		System.out.println("pin");
 			final int offset = evt.getOffset();
 			final int length = evt.getLength();
 			final String text = evt.getText();
@@ -75,14 +77,11 @@
 					try {
 						document.replace(offset, 0, text);
 					} catch (BadLocationException e) {
-						// TODO Auto-generated catch block
 						e.printStackTrace();
 					}
 				}
 		    });
 			}
-		
-//	document.replace(1, 4, "hugo");
 	}