D21730: Pass gridLayout pointer to createStyleWidget

Shubham noreply at phabricator.kde.org
Mon Jun 10 17:51:28 BST 2019


shubham added inline comments.

INLINE COMMENTS

> annotationwidgets.cpp:817
>  {
> -    QWidget * widget = new QWidget();
> -    QVBoxLayout * lay = new QVBoxLayout( widget );
> -    lay->setMargin( 0 );
> -    QGroupBox * gb = new QGroupBox( widget );
> -    lay->addWidget( gb );
> -    gb->setTitle( i18n( "Caret Symbol" ) );
> -    QHBoxLayout * gblay = new QHBoxLayout( gb );
> -    m_pixmapSelector = new PixmapPreviewSelector( gb );
> -    gblay->addWidget( m_pixmapSelector );
> +    QWidget * widget = (QWidget*)formlayout->parent();
> +

Why not use qobject_cast here and cases above?

REPOSITORY
  R223 Okular

REVISION DETAIL
  https://phabricator.kde.org/D21730

To: simgunz
Cc: shubham, ngraham, okular-devel, joaonetto, tfella, darcyshen, aacid
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/okular-devel/attachments/20190610/4f80f04f/attachment-0001.html>


More information about the Okular-devel mailing list