Opened 16 years ago
Closed 16 years ago
Last modified 16 years ago
#5596 closed task (fixed)
port libmyth to Qt4
Reported by: | danielk | Owned by: | danielk |
---|---|---|---|
Priority: | minor | Milestone: | 0.22 |
Component: | mythtv | Version: | head |
Severity: | medium | Keywords: | |
Cc: | Ticket locked: | no |
Description
Attachments (17)
Change History (75)
Changed 16 years ago by
Attachment: | 5596-v1.patch.bz2 added |
---|
comment:1 Changed 16 years ago by
The patch currently breaks a lot of things, and there are a lot of TODO's in the code, but it compiles :)
comment:2 Changed 16 years ago by
Changed 16 years ago by
Attachment: | 5596-v3.patch.bz2 added |
---|
Adds a couple Qt3 UI classes to mythmusic to allow plugin to compile with qt4 libmyth.
Changed 16 years ago by
Attachment: | 5596-v5.patch.bz2 added |
---|
Implements most of the TODO's in the patch
Changed 16 years ago by
Attachment: | 5596-v6.patch.bz2 added |
---|
comment:3 Changed 16 years ago by
Note: As of the last patch all the code segments marked TODO in the earlier patch have been implemented. There are still problems remaining, mostly having to do with signal/slots having been renamed in Qt4.
comment:4 Changed 16 years ago by
Had lots of errors like:
diseqcsettings.cpp:950: error: no matching function for call to 'MythListBox::setCurrentRow(int, QItemSelectionModel::SelectionFlag)' /Volumes/MythBuild/.osx-packager/build/include/QtGui/qlistwidget.h:229: note: candidates are: void QListWidget::setCurrentRow(int)
Instead of changing all the code's setSelected(), am wondering if it might be easier to have a wrapper method MythListBox::setSelected(const int i, const bool flag) { setCurrentRow(i); (void)flag; };
Changed 16 years ago by
Attachment: | 5596-v7.patch.bz2 added |
---|
no improvements, just updated to the latest svn
comment:5 Changed 16 years ago by
Nigel, that's my fault. I used a Qt 4.4 function, in Qt 4.0 through 4.3 there is no selection model parameter. I'll fix this in the next round.
comment:6 Changed 16 years ago by
Changed 16 years ago by
Attachment: | 5596-v9.patch.bz2 added |
---|
Updated patch, this one should compile with Qt 4.3.
comment:7 Changed 16 years ago by
For some reason:
patching file mythtv/libs/libmyth/mediamonitor-unix.cpp Hunk #3 FAILED at 160.
Still testing, but this really is mammoth. I might start applying the little parts that I have tested, if that's OK?
comment:8 Changed 16 years ago by
Nigel, more than ok. :)
I'm super busy with work for the next few weeks, but the smaller this patch gets the easier it will be to apply. The media monitor code contains some fixes too which I was planning to factor out anyway (I wasn't able to test the media monitor changes until I got the existing media monitor code to work on my machine first...)
There is also a known bug with the exit from mythtv dialog (when configured to prompt on exit), other dialogs I tested appeared to work, but this is probably a generic failure of some sort. My first suspicion with these is that some Qt slot has been renamed, but I didn't notice any complaints about that when entering mythtv and trying to exit immediately, so this may be something like a changed Dialog result code, or something else entirely. I haven't had a chance to look at it myself other than to note the problem.
comment:9 Changed 16 years ago by
comment:10 Changed 16 years ago by
The last patch does not compile, because in the header it says:
static const QString kUDEV_FIFO;
And the cpp says:
const char * MediaMonitorUnix::kUDEV_FIFO = "/tmp/mythtv_media";
So the patch would be:
Index: libs/libmyth/mediamonitor-unix.h =================================================================== --- libs/libmyth/mediamonitor-unix.h (revision 18300) +++ libs/libmyth/mediamonitor-unix.h (working copy) @@ -23,7 +23,7 @@ protected: int m_fifo; - static const QString kUDEV_FIFO; + static const char * kUDEV_FIFO; }; #endif // MYTH_MEDIA_MONITOR_H
comment:11 Changed 16 years ago by
comment:12 Changed 16 years ago by
comment:13 Changed 16 years ago by
(In [18319]) The last of Daniel's Qt3->Qt4 in this file. See #5596. I am unable to test the CheckDeviceNotifications??() changes, because my udev setup only sends "mount/umount" notifications, not "add/remove" ones. The code is nearly identical to that in CheckMountable??(), so it should be good. (hint, someone could create a CheckRemovable??)
comment:14 Changed 16 years ago by
comment:15 Changed 16 years ago by
comment:16 Changed 16 years ago by
comment:18 Changed 16 years ago by
comment:19 Changed 16 years ago by
(In [18328]) A few more Qt3isms gone. See #5596. I hadn't realised that QObject::tr(QString) is now unsafe. Its one of the few Qt methods that uses a char * instead of a QString. TrollTech? should provide a QString one?
comment:20 Changed 16 years ago by
comment:25 Changed 16 years ago by
comment:26 Changed 16 years ago by
comment:27 Changed 16 years ago by
(In [18390]) Remove Qt3-isms. Slightly simpler version of Daniel's patch. See #5596. (I changed the MythListBox? to a QListWidget for now)
comment:29 Changed 16 years ago by
Changed 16 years ago by
Attachment: | 5596-v12.patch.bz2 added |
---|
comment:30 Changed 16 years ago by
v12 patch has some of the MythThemedDialog? subclasses that were missed (in the plugins). Looking at all those method signature changes, I think we should just stay with the char*, and do this in mythwidgets.cpp and mythdialogs.cpp.
if (name) setObjectName(QString(name));
if necessary.
I'm hoping to have some time to change settings.cpp to use the new MythUI, but we'll see?
comment:31 Changed 16 years ago by
comment:33 Changed 16 years ago by
comment:34 Changed 16 years ago by
comment:35 Changed 16 years ago by
(In [18483]) Pass const QString refs to MythThemedDialog?, default object name. See #5596
comment:36 Changed 16 years ago by
comment:37 Changed 16 years ago by
comment:38 Changed 16 years ago by
comment:39 Changed 16 years ago by
comment:40 Changed 16 years ago by
(In [18589]) Refs #5596. Port MythListBox? to Qt4.
Note: MythMusic was the only user of MythListView? and also used some funky aspects of MythListBox?, so it now has it's own copies of these two Qt3 classes and MythListView? is gone from libmyth. I didn't try to port mythmusic to Qt4 since I understand there is already an effort to port it to MythUI.
comment:41 Changed 16 years ago by
comment:42 Changed 16 years ago by
comment:43 Changed 16 years ago by
comment:44 Changed 16 years ago by
comment:45 Changed 16 years ago by
comment:46 Changed 16 years ago by
comment:47 Changed 16 years ago by
Note: #5792 should be applied before closing this ticket, in addition to other changes, It changes some Qt3 compat calls to Qt4 calls.
comment:48 Changed 16 years ago by
(In [18608]) Refs #5596. Connect correct signal for selection updates in ProgLister?; this was broken by [18602] this morning.
comment:49 Changed 16 years ago by
comment:50 Changed 16 years ago by
comment:51 Changed 16 years ago by
comment:52 Changed 16 years ago by
comment:53 Changed 16 years ago by
(In [18647]) Refs #5596. Port StackedConfigurationGroup? from Qt3 to Qt4.
comment:54 Changed 16 years ago by
(In [18649]) Refs #5596. Port MythWizard? to Qt4, remove TabbedConfiguratioGroup? (which wasn't being used anywhere).
comment:55 Changed 16 years ago by
(In [18650]) Refs #5596. Gets rid of Q3SimpleRichText.
Note the rendering is by no means as pretty with the new Qt4 rich text handler. It can be, but now we need to use CSS for the same effect, and I did not bother to make this pixel perfect since this should soon be replaced with a MythUI component.
comment:57 Changed 16 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
Preliminary patch