mirror of
https://github.com/kotatogram/kotatogram-desktop
synced 2025-08-31 06:35:14 +00:00
removed interfaces pointer by default from BasicInterface
This commit is contained in:
@@ -270,7 +270,7 @@ public:
|
||||
|
||||
class OverviewItemInfo : public BasicInterface<OverviewItemInfo> {
|
||||
public:
|
||||
OverviewItemInfo() : _top(0) {
|
||||
OverviewItemInfo(Interfaces *) : _top(0) {
|
||||
}
|
||||
int32 top() const {
|
||||
return _top;
|
||||
|
@@ -39,7 +39,7 @@ template <typename Type>
|
||||
struct InterfaceWrapTemplate {
|
||||
static const int Size = CeilDivideMinimumOne<sizeof(Type), sizeof(uint64)>::Result * sizeof(uint64);
|
||||
static void Construct(void *location, Interfaces *interfaces) {
|
||||
(new (location) Type())->interfaces = interfaces;
|
||||
new (location) Type(interfaces);
|
||||
}
|
||||
static void Destruct(void *location) {
|
||||
((Type*)location)->~Type();
|
||||
@@ -72,6 +72,14 @@ public:
|
||||
static const uint64 Bit() {
|
||||
return (1 << Index());
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
template <typename Type>
|
||||
class BasicInterfaceWithPointer : public BasicInterface<Type> {
|
||||
public:
|
||||
BasicInterfaceWithPointer(Interfaces *interfaces) : interfaces(interfaces) {
|
||||
}
|
||||
Interfaces *interfaces = 0;
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user