- connect(okPB, SIGNAL(clicked()), form_, SLOT(slotOK()));
- connect(applyPB, SIGNAL(clicked()), form_, SLOT(slotApply()));
- connect(closePB, SIGNAL(clicked()), form_, SLOT(slotClose()));
- connect(closePB, SIGNAL(clicked()), this, SLOT(reset_dialog()));
- connect(this, SIGNAL(rejected()), this, SLOT(reset_dialog()));
+ at_ref_ = false;
+
+ // Enabling is set in updateRefs. Disable for now in case no
+ // call to updateContents follows (e.g. read-only documents).
+ sortCB->setEnabled(false);
+ caseSensitiveCB->setEnabled(false);
+ caseSensitiveCB->setChecked(false);
+ refsLW->setEnabled(false);
+ gotoPB->setEnabled(false);
+
+ connect(okPB, SIGNAL(clicked()), this, SLOT(slotOK()));
+ connect(applyPB, SIGNAL(clicked()), this, SLOT(slotApply()));
+ connect(closePB, SIGNAL(clicked()), this, SLOT(slotClose()));
+ connect(closePB, SIGNAL(clicked()), this, SLOT(resetDialog()));
+ connect(this, SIGNAL(rejected()), this, SLOT(dialogRejected()));