[Kmymoney-devel] [Bug 276322] Unwanted fields show in ledger for investment.
agander93 at gmail.com
Sat Aug 27 19:32:31 UTC 2011
--- Comment #12 from allan <agander93 gmail com> 2011-08-27 19:32:31 ---
(In reply to comment #3)
> (In reply to comment #2)
> > One thing you could try is to replace
> > w->hide();
> > with
> > QTimer::singleShot(0, w, SLOT(hide()));
> > If that does not work, try if replacing 0 with a value of 1000 makes a
> > difference.
Eventually, I settled on a value of '1', which has worked nicely, and I had to
use it quite a lot.
However, and unexpectedly, I think I found why it appeared necessary, when I
had accepted it and wasn't looking any deeper.
After a break, when I was doing a tidy up, one of the widgets which I had got
to work correctly, appeared again when it should have been hidden. Immediately
on opening a new investment transaction, when 'Buy shares' was displayed, but
hadn't been selected, the 'Interest' widget was visible, when it shouldn't have
been. When 'Buy shares' was selected, the widget correctly was hidden.
I found that in InvestTransactionEditor::slotUpdateActivity(),
'haveWidget("interest-account")->parentWidget()->hide()' didn't hide the
combobox. When I removed the 'parentWidget()' element, I was able to revert
the majority of the cases where I'd needed to use the QTimer.
Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
More information about the KMyMoney-devel