AW: MarbleWidget viewContext property

Martin Koller kollix at aon.at
Fri Jul 13 11:44:40 BST 2018


> > -----Original-Nachricht-----
> > Betreff: MarbleWidget viewContext property
> > Datum: 2018-07-04T11:24:10+0200
> > Von: "Martin Koller" <kollix at aon.at>
> > An: "marble-devel at kde.org" <marble-devel at kde.org>
> > 
> > In MarbleWidget there is
> >     Q_PROPERTY(ViewContext viewContext READ viewContext WRITE setViewContext NOTIFY viewContextChanged)
> > 
> > however, ViewContext is not registered with the Qt meta-object system as it is not in a QObject of QGadget.
> > 
> > So I get the following warnings in runtime:
> > QMetaProperty::read: Unable to handle unregistered datatype 'ViewContext' for property 'Marble::MarbleWidget::viewContext'
> > 
> > What shall be done here ?

> -----Original-Nachricht-----
> Betreff: Re: AW: MarbleWidget viewContext property
> Datum: 2018-07-11T18:35:46+0200
> Von: "Martin Koller" <kollix at aon.at>
> An: "tackat at t-online.de" <tackat at t-online.de>
> 
> On Mittwoch, 11. Juli 2018 15:53:40 CEST tackat at t-online.de wrote:
> > 
> > Hi Martin,
> > 
> > ... and indeed the implementation of MarbleWidget::setViewContext() doesn't emit a signal.
> > I guess it's not being used as a property inside Marble itself.
> > Do you have any suggestion for a fix? 
> 
> What about removing the Q_PROPERTY macro then ?

On Mittwoch, 11. Juli 2018 18:43:47 CEST tackat at t-online.de wrote:

> 
> That would be fine with me :-)
> 
> Best Regards,
> Torsten

What I find is that a signal from the Map is forwarded to the widget signal.

    m_widget->connect( &m_map,   SIGNAL(viewContextChanged(ViewContext)),
                       m_widget, SIGNAL(viewContextChanged(ViewContext)) );

and the property was added by Daniel with
339f1c42bba812f5db02b56a8909c6e59b146eb9

So I'm not sure what to do here.
Is the property probably somehow needed in QML ? (I have no clue about QML)
But since the enum is not registered with the meta type system, would that work ?

-- 
Best regards/Schöne Grüße

Martin
A: Because it breaks the logical sequence of discussion
Q: Why is top posting bad?

()  ascii ribbon campaign - against html e-mail 
/\                        - against proprietary attachments

Geschenkideen, Accessoires, Seifen, Kulinarisches: www.lillehus.at




More information about the Marble-devel mailing list