Fix build on macOS.
This commit is contained in:
parent
d2ae2cf8f6
commit
914df12ebe
1 changed files with 9 additions and 9 deletions
|
|
@ -44,15 +44,6 @@ private:
|
||||||
|
|
||||||
} // namespace details
|
} // namespace details
|
||||||
|
|
||||||
template <typename Value>
|
|
||||||
inline not_null<details::AttachmentOwner<std::decay_t<Value>>*> WrapAsQObject(
|
|
||||||
not_null<QObject*> parent,
|
|
||||||
Value &&value) {
|
|
||||||
return CreateChild<details::AttachmentOwner<std::decay_t<Value>>>(
|
|
||||||
parent.get(),
|
|
||||||
std::forward<Value>(value));
|
|
||||||
}
|
|
||||||
|
|
||||||
template <typename Widget, typename ...Args>
|
template <typename Widget, typename ...Args>
|
||||||
inline base::unique_qptr<Widget> CreateObject(Args &&...args) {
|
inline base::unique_qptr<Widget> CreateObject(Args &&...args) {
|
||||||
return base::make_unique_q<Widget>(
|
return base::make_unique_q<Widget>(
|
||||||
|
|
@ -75,6 +66,15 @@ inline Value *CreateChild(
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
template <typename Value>
|
||||||
|
inline not_null<details::AttachmentOwner<std::decay_t<Value>>*> WrapAsQObject(
|
||||||
|
not_null<QObject*> parent,
|
||||||
|
Value &&value) {
|
||||||
|
return CreateChild<details::AttachmentOwner<std::decay_t<Value>>>(
|
||||||
|
parent.get(),
|
||||||
|
std::forward<Value>(value));
|
||||||
|
}
|
||||||
|
|
||||||
inline void DestroyChild(QWidget *child) {
|
inline void DestroyChild(QWidget *child) {
|
||||||
delete child;
|
delete child;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue