Examples of DocumentAdapter


Examples of com.intellij.openapi.editor.event.DocumentAdapter

  public static final Set<VirtualFile> CHANGED_FILES = new CopyOnWriteArraySet<VirtualFile>();

  protected DocumentChangeListener(final Project project) {
    super(project);

    EditorFactory.getInstance().getEventMulticaster().addDocumentListener(new DocumentAdapter() {

      @Override
      public void documentChanged(final DocumentEvent e) {
        rememberChangedFile(e);
View Full Code Here

Examples of com.intellij.openapi.editor.event.DocumentAdapter

          public void run() {
            VirtualFile virtualFile = VfsUtil.findFileByIoFile(configurationFile, false);
            if (virtualFile != null && virtualFile.isValid()) {
              Document document = FileDocumentManager.getInstance().getDocument(virtualFile);
              if (document != null) {
                document.addDocumentListener(new DocumentAdapter() {
                  @Override
                  public void documentChanged(DocumentEvent e) {
                    myConfigChanged.set(true);
                  }
                }, parentDisposable);
View Full Code Here

Examples of com.intellij.openapi.editor.event.DocumentAdapter

     */
    public MarkdownPreviewEditor(@NotNull Project project, @NotNull Document document) {
        this.document = document;

        // Listen to the document modifications.
        this.document.addDocumentListener(new DocumentAdapter() {
            @Override
            public void documentChanged(DocumentEvent e) {
                previewIsObsolete = true;
            }
        });
View Full Code Here

Examples of com.intellij.openapi.editor.event.DocumentAdapter

      JComponent activationComponent = WindowManager.getInstance().getFrame(project).getRootPane();
      project.putUserData(LIVE_PREVIEW_QUEUE, queue = new MergingUpdateQueue("LIVE_PREVIEW_QUEUE", 1000, true, null, project, activationComponent));
    }
    final FileEditorManager fileEditorManager = FileEditorManager.getInstance(project);
    final MergingUpdateQueue finalQueue = queue;
    EditorFactory.getInstance().getEventMulticaster().addDocumentListener(new DocumentAdapter() {
      @Override
      public void documentChanged(DocumentEvent e) {
        Document document = e.getDocument();
        final FileDocumentManager fileDocumentManager = FileDocumentManager.getInstance();
        VirtualFile file = fileDocumentManager.getFile(document);
View Full Code Here

Examples of com.intellij.openapi.editor.event.DocumentAdapter

        return false;
      }

    });

    EditorFactory.getInstance().getEventMulticaster().addDocumentListener(new DocumentAdapter() {
      @Override
      public void documentChanged(DocumentEvent e) {
//        scheduleProjectSave();
      }
    });
View Full Code Here

Examples of com.intellij.ui.DocumentAdapter

        };
    }

    @Override
    protected DocumentListener createDocumentListener() {
        return new DocumentAdapter() {
            @Override
            protected void textChanged(DocumentEvent e) {
                getConfiguration().setModified(true);
                updatePreview();
            }
View Full Code Here

Examples of com.intellij.ui.DocumentAdapter

    public abstract void applyChanges() throws ConfigurationException;
    public abstract void resetChanges();

    protected DocumentListener createDocumentListener() {
        return new DocumentAdapter() {
            protected void textChanged(DocumentEvent e) {
                getConfiguration().setModified(true);
            }
        };
    }
View Full Code Here

Examples of com.intellij.ui.DocumentAdapter

      FileTextField fileTextField = FileChooserFactory.getInstance().createFileTextField(
        fileChooser.getDescriptor(), false, myDisposable);

      tfFile = fileTextField.getField();
      tfFile.setColumns(60);
      DocumentAdapter textFieldsListener = new DocumentAdapter()
      {
        public void textChanged(DocumentEvent event)
        {
          setOKActionEnabled(!tfFile.getText().trim().equals(review.getFile()));
        }
View Full Code Here

Examples of com.intellij.ui.DocumentAdapter

    public void setConnectionId(String connectionId) {
        this.connectionId = connectionId;
    }

    protected DocumentListener createDocumentListener() {
        return new DocumentAdapter() {
            protected void textChanged(DocumentEvent e) {
                GenericConnectionDatabaseSettings connectionConfig = getConfiguration();
                connectionConfig.setModified(true);

                Document document = e.getDocument();
View Full Code Here

Examples of com.intellij.ui.DocumentAdapter

          }
          return super.getInitialFile();
        }
    });

    final DocumentListener updateOkButtonListener = new DocumentAdapter() {
      @Override protected void textChanged(DocumentEvent e) {
        updateButtons();
      }
    };
    myParentDirectory.getChildComponent().getDocument().addDocumentListener(updateOkButtonListener);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.