equal
deleted
inserted
replaced
33 QWidget(parent), mainLayout(this) |
33 QWidget(parent), mainLayout(this) |
34 { |
34 { |
35 imageButt=new QPushButton(this); |
35 imageButt=new QPushButton(this); |
36 imageButt->setFixedSize(256, 128); |
36 imageButt->setFixedSize(256, 128); |
37 imageButt->setFlat(true); |
37 imageButt->setFlat(true); |
38 imageButt->setSizePolicy(QSizePolicy::Minimum, QSizePolicy::Minimum); |
38 imageButt->setSizePolicy(QSizePolicy::Fixed, QSizePolicy::Fixed);//QSizePolicy::Minimum, QSizePolicy::Minimum); |
39 mainLayout.addWidget(imageButt); |
39 mainLayout.addWidget(imageButt); |
40 connect(imageButt, SIGNAL(clicked()), this, SLOT(setRandomSeed())); |
40 connect(imageButt, SIGNAL(clicked()), this, SLOT(setRandomSeed())); |
41 setRandomSeed(); |
41 setRandomSeed(); |
42 |
42 |
43 chooseMap=new QComboBox(this); |
43 chooseMap=new QComboBox(this); |
49 mapList.push_front(QComboBox::tr("generated map...")); |
49 mapList.push_front(QComboBox::tr("generated map...")); |
50 chooseMap->addItems(mapList); |
50 chooseMap->addItems(mapList); |
51 connect(chooseMap, SIGNAL(activated(int)), this, SLOT(mapChanged(int))); |
51 connect(chooseMap, SIGNAL(activated(int)), this, SLOT(mapChanged(int))); |
52 |
52 |
53 mainLayout.addWidget(chooseMap); |
53 mainLayout.addWidget(chooseMap); |
|
54 mainLayout.setSizeConstraint(QLayout::SetFixedSize);//SetMinimumSize |
54 } |
55 } |
55 |
56 |
56 void HWMapContainer::setImage(const QImage newImage) |
57 void HWMapContainer::setImage(const QImage newImage) |
57 { |
58 { |
58 QPixmap px(256, 128); |
59 QPixmap px(256, 128); |