OpenConcerto

Dépôt officiel du code source de l'ERP OpenConcerto
sonarqube

svn://code.openconcerto.org/openconcerto

Rev

Rev 19 | Rev 41 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 19 Rev 25
Line 13... Line 13...
13
 
13
 
14
 package org.openconcerto.sql.sqlobject;
14
 package org.openconcerto.sql.sqlobject;
15
 
15
 
16
import org.openconcerto.sql.model.SQLField;
16
import org.openconcerto.sql.model.SQLField;
17
import org.openconcerto.sql.model.SQLRow;
17
import org.openconcerto.sql.model.SQLRow;
18
import org.openconcerto.sql.model.SQLTable;
18
import org.openconcerto.sql.model.SQLTableEvent;
19
import org.openconcerto.sql.model.SQLTableListener;
19
import org.openconcerto.sql.model.SQLTableModifiedListener;
20
import org.openconcerto.sql.model.Where;
20
import org.openconcerto.sql.model.Where;
21
import org.openconcerto.sql.request.ComboSQLRequest;
21
import org.openconcerto.sql.request.ComboSQLRequest;
22
import org.openconcerto.ui.component.text.TextComponent;
22
import org.openconcerto.ui.component.text.TextComponent;
23
import org.openconcerto.utils.OrderedSet;
23
import org.openconcerto.utils.OrderedSet;
24
 
-
 
25
import org.openconcerto.utils.checks.MutableValueObject;
24
import org.openconcerto.utils.checks.MutableValueObject;
26
import org.openconcerto.utils.text.DocumentFilterList;
25
import org.openconcerto.utils.text.DocumentFilterList;
27
import org.openconcerto.utils.text.LimitedSizeDocumentFilter;
-
 
28
import org.openconcerto.utils.text.DocumentFilterList.FilterType;
26
import org.openconcerto.utils.text.DocumentFilterList.FilterType;
-
 
27
import org.openconcerto.utils.text.LimitedSizeDocumentFilter;
29
 
28
 
30
import java.awt.Component;
29
import java.awt.Component;
31
import java.awt.GridLayout;
30
import java.awt.GridLayout;
32
import java.awt.event.ComponentEvent;
31
import java.awt.event.ComponentEvent;
33
import java.awt.event.ComponentListener;
32
import java.awt.event.ComponentListener;
Line 116... Line 115...
116
            setPopupInvoker(this);
115
            setPopupInvoker(this);
117
        }
116
        }
118
 
117
 
119
        this.isLoading = true;
118
        this.isLoading = true;
120
        loadCacheAsynchronous();
119
        loadCacheAsynchronous();
121
        this.comboRequest.addTableListener(new SQLTableListener() {
-
 
122
 
-
 
123
            public void rowAdded(SQLTable table, int id) {
-
 
124
                loadCacheAsynchronous();
120
        // FIXME never removed
125
            }
-
 
126
 
-
 
127
            public void rowDeleted(SQLTable table, int id) {
121
        this.comboRequest.addTableListener(new SQLTableModifiedListener() {
128
                loadCacheAsynchronous();
-
 
129
            }
122
            @Override
130
 
-
 
131
            public void rowModified(SQLTable table, int id) {
123
            public void tableModified(SQLTableEvent evt) {
132
                loadCacheAsynchronous();
124
                loadCacheAsynchronous();
133
            }
125
            }
134
        });
126
        });
135
    }
127
    }
136
 
128