Révision 3699

TXM/trunk/bundles/org.txm.internalview.rcp/src/org/txm/internalview/rcp/handlers/BackToInternalView.java (revision 3699)
36 36
			
37 37
			InternalViewEditor editor = (InternalViewEditor) page.openEditor(editorInput, InternalViewEditor.class.getName()); // $NON-NLS-1$
38 38
			editor.backToText(match);
39
			SWTEditorsUtils.addEditor(sourceEditor, editor, EModelService.ABOVE);
39
			if (editor != null) {
40
				SWTEditorsUtils.addEditor(sourceEditor, editor, EModelService.ABOVE);
41
			}
40 42
		}
41 43
		catch (Exception e) {
42 44
			System.err.println(InternalViewUIMessages.bind(InternalViewUIMessages.error_backto_internalview, e));
TXM/trunk/bundles/org.txm.progression.rcp/src/org/txm/progression/rcp/chartsengine/events/ProgressionEventCallBack.java (revision 3699)
247 247
					System.err.println("ProgressionEventCallBack.updateLinkedConcordanceEditor(): parent editor for splitting: " + parentEditor); //$NON-NLS-1$
248 248
				}
249 249
				// Split and add linked editor
250
				SWTEditorsUtils.addEditor(parentEditor, linkedEditor, position);
250
				if (parentEditor != null && position >= 0) {
251
					SWTEditorsUtils.addEditor(parentEditor, linkedEditor, position);
252
				}
251 253
			}
252 254
			
253 255
		}
......
458 460
					linkedEditor = OpenEdition.openEdition(corpus, OpenEdition.getDefaultEditions(corpus));
459 461
					chartEditor.addLinkedEditor(linkedEditor);
460 462
					
461
					
462 463
					int position = EModelService.BELOW;
463 464
					;
464 465
					EditorPart parentEditor = chartEditor;
......
470 471
					}
471 472
					
472 473
					// Split and add linked editor
473
					SWTEditorsUtils.addEditor(parentEditor, linkedEditor, position);
474
					if (parentEditor != null && position >= 0) {
475
						SWTEditorsUtils.addEditor(parentEditor, linkedEditor, position);
476
					}
474 477
				}
475 478
				
476 479
				linkedEditor.goToPage(text.getName(), openPage.getName());
......
495 498
				// chartEditor.getChartComposite().setFocus();
496 499
				// }
497 500
				// });
498
				
499 501
			}
500 502
		}
501 503
		catch (Exception e) {

Formats disponibles : Unified diff