Révision 2254
tmp/org.txm.edition.rcp/src/org/txm/edition/rcp/editors/EditionPanel.java (revision 2254) | ||
---|---|---|
771 | 771 |
String id; |
772 | 772 |
try { |
773 | 773 |
String[] ids = this.synopticEditionEditor.getCorpus().getCorpusTextIdsList(); |
774 |
String current = currentText.getName(); |
|
775 |
int idx = Arrays.binarySearch(ids, current); |
|
774 |
String currentId = currentText.getName(); |
|
775 |
int idx = 0; |
|
776 |
for (int i = 0 ; i < ids.length ;i++) { |
|
777 |
if (currentId.equals(ids[i])) { |
|
778 |
idx = i; |
|
779 |
break; |
|
780 |
} |
|
781 |
} |
|
776 | 782 |
if (idx > 0) idx--; |
777 | 783 |
id = ids[idx]; |
778 | 784 |
} catch (Exception e) { |
... | ... | |
815 | 821 |
try { |
816 | 822 |
String[] ids = this.synopticEditionEditor.getCorpus().getCorpusTextIdsList(); |
817 | 823 |
String currentId = currentText.getName(); |
818 |
int idx = Arrays.binarySearch(ids, currentId); |
|
824 |
int idx = 0; |
|
825 |
for (int i = 0 ; i < ids.length ;i++) { |
|
826 |
if (currentId.equals(ids[i])) { |
|
827 |
idx = i; |
|
828 |
break; |
|
829 |
} |
|
830 |
} |
|
819 | 831 |
if (idx < ids.length - 1) idx++; |
820 | 832 |
id = ids[idx]; |
821 | 833 |
} catch (Exception e) { |
Formats disponibles : Unified diff