30,6 → 30,7 |
import com.gwtext.client.widgets.Panel; |
import com.gwtext.client.widgets.event.ContainerListener; |
import com.gwtext.client.widgets.event.ContainerListenerAdapter; |
import com.gwtext.client.widgets.event.DataViewListener; |
import com.gwtext.client.widgets.event.DataViewListenerAdapter; |
import com.gwtext.client.widgets.event.PanelListenerAdapter; |
import com.gwtext.client.widgets.grid.GridDragData; |
66,7 → 67,7 |
*/ |
private boolean estInstancie = false; |
|
private boolean garderRatio = false; |
private boolean garderRatio = true; |
|
private int tailleOr = 100 ; |
|
248,8 → 249,8 |
new String[] { |
"<tpl for='.'>", |
"<div class='thumb-wrap' id='{num_image}'>", |
"<div class='thumb'><img src='{url_image_M}' width='{taille_x_s} px' height='{taille_y_s} px' title='{num_image}'></div>", |
"<span>{nom}</span></div>", "</tpl>", |
"<div class='thumb dview-list'><img src='{url_image_M}' width='{taille_x_s} px' height='{taille_y_s} px' title='{nom_original}'></div>", |
"<span></span></div>", "</tpl>", |
"<div class='x-clear'></div>" }); |
// pour des raisons de performances on compile le template en une |
// fonction |
261,7 → 262,7 |
|
public void prepareData(Data data) { |
data.setProperty("shortName", Format.ellipsis(data |
.getProperty("num_image"), 15)); |
.getProperty("nom_original"), 15)); |
|
int[] XY = {data.getPropertyAsInt("taille_x") ,data.getPropertyAsInt("taille_y")} ; |
int[] XYresize ; |
290,6 → 291,7 |
|
// creation du store |
FieldDef defNumImage = new IntegerFieldDef("num_image"); |
FieldDef defNomImage = new StringFieldDef("nom_original"); |
FieldDef defDatImage = new StringFieldDef("dat_image"); |
FieldDef defLieImage = new StringFieldDef("lie_image"); |
FieldDef defAppImage = new StringFieldDef("app_image"); |
298,7 → 300,7 |
FieldDef defUrlImage = new StringFieldDef("url_image"); |
FieldDef defTailleX = new IntegerFieldDef("taille_x"); |
FieldDef defTailleY = new IntegerFieldDef("taille_y"); |
FieldDef[] defTab = { defNumImage, defDatImage, defLieImage, |
FieldDef[] defTab = { defNumImage, defNomImage, defDatImage, defLieImage, |
defAppImage, defUrlImageS, defUrlImageM, defUrlImage,defTailleX,defTailleY}; |
RecordDef rd = new RecordDef(defTab); |
st = new Store(rd); |