Pokered Save Editor 2
Pokemon Red & Blue save file editor - Qt 6 C++/QML
Loading...
Searching...
No Matches
examples.h
Go to the documentation of this file.
1/*
2 * Copyright 2020 Twilight
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15*/
16#pragma once
17#include <QObject>
18
22
23class QQmlEngine;
24
35class Examples : public QObject
36{
37 Q_OBJECT
38 Q_PROPERTY(ExamplesPlayer* player READ player CONSTANT)
39 Q_PROPERTY(ExamplesRival* rival READ rival CONSTANT)
40 Q_PROPERTY(ExamplesPokemon* pokemon READ pokemon CONSTANT)
41
42public:
43 static Examples* inst();
44
45 ExamplesPlayer* player() const;
46 ExamplesRival* rival() const;
47 ExamplesPokemon* pokemon() const;
48
49public slots:
50 void qmlProtect(const QQmlEngine* const engine) const;
51
52private slots:
53 void qmlRegister() const;
54
55private:
56 Examples();
57};
Example player-value source (an AbstractRandomString of presets).
Example Pokemon-value source (an AbstractRandomString of presets).
Example rival-value source (an AbstractRandomString of presets).
ExamplesRival * rival() const
The example-rival source (backs rival).
Definition examples.cpp:42
ExamplesPokemon * pokemon() const
The example-Pokemon source (backs pokemon).
Definition examples.cpp:47
void qmlProtect(const QQmlEngine *const engine) const
Pin to C++ ownership.
Definition examples.cpp:52
ExamplesPlayer * player() const
The example-player source (backs player).
Definition examples.cpp:37
static Examples * inst()
< Example player source.
Definition examples.cpp:31