Skip to content

Commit bd90bc2

Browse files
committed
minor improvement to ViewPropEdit backspace key handling (takes you to the visually preceeding node more reliably)
1 parent 5f391fb commit bd90bc2

File tree

3 files changed

+8
-9
lines changed

3 files changed

+8
-9
lines changed

src/org/argmap/client/ArgMap.java

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44

55
import com.google.gwt.core.client.EntryPoint;
66
import com.google.gwt.core.client.GWT;
7-
import com.google.gwt.core.client.RunAsyncCallback;
87
import com.google.gwt.core.client.GWT.UncaughtExceptionHandler;
8+
import com.google.gwt.core.client.RunAsyncCallback;
99
import com.google.gwt.dom.client.Style;
1010
import com.google.gwt.event.logical.shared.SelectionEvent;
1111
import com.google.gwt.event.logical.shared.SelectionHandler;
@@ -22,7 +22,6 @@
2222
import com.google.gwt.user.client.ui.TabLayoutPanel;
2323
import com.google.gwt.user.client.ui.Widget;
2424

25-
//TODO: on backspace delete of node skips preceeding link sibling and focuses on parent arg
2625
//TODO: rating an item seems to scroll it out of view!
2726
//TODO: deleting an items sometimes causes view to scroll to seemingly unrelated place...
2827
//TODO: the text of linked propositions and their children does not automatically update when edited elsewhere within the same window...
@@ -262,8 +261,8 @@ public void onSuccess() {
262261
public void onFailure(Throwable reason) {
263262
ArgMap.messageTimed("Code download failed",
264263
MessageType.ERROR);
265-
Log.log("am.sv.a.of", "Code download failed"
266-
+ reason.toString());
264+
Log.log("am.sv.a.of",
265+
"Code download failed" + reason.toString());
267266
}
268267
});
269268
}
@@ -402,8 +401,7 @@ public void onUncaughtException(Throwable e) {
402401
} catch (Exception handlerException) {
403402
}
404403
GWT.log("Uncaught Exception", e);
405-
if (Log.on)
406-
Log.finishOpenLogs();
404+
if (Log.on) Log.finishOpenLogs();
407405
}
408406

409407
public ModeEdit getModeEdit() {

src/org/argmap/client/ViewPropEdit.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -533,7 +533,8 @@ else if (charCode == KeyCodes.KEY_BACKSPACE
533533
&& textArea.getCursorPos() == 0) {
534534
ViewPropEdit preceedingSibling = getPreceedingSibling();
535535
if (preceedingSibling != null && !preceedingSibling.isLink()
536-
&& !isLink() && !isTopLevel()) {
536+
&& !isLink() && !isTopLevel()
537+
&& !textArea.getText().equals("")) {
537538
if (getChildCount() == 0) {
538539
/* merge With Previous Sibling */
539540
mergePropsAndDeleteOne(preceedingSibling, this,

war/WEB-INF/appengine-generated/datastore-indexes-auto.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
<!-- Indices written at Sun, 12 Dec 2010 18:41:39 EST -->
1+
<!-- Indices written at Mon, 13 Dec 2010 14:50:28 UTC -->
22

33
<datastore-indexes>
44

5-
<!-- Used 28 times in query history -->
5+
<!-- Used 2 times in query history -->
66
<datastore-index kind="Proposition" ancestor="false" source="auto">
77
<property name="root" direction="asc"/>
88
<property name="created" direction="desc"/>

0 commit comments

Comments
 (0)