summaryrefslogtreecommitdiff
path: root/gi/repo.cpp
diff options
context:
space:
mode:
authorPhilip Chimento <philip.chimento@gmail.com>2017-12-10 00:29:29 -0800
committerPhilip Chimento <philip.chimento@gmail.com>2018-07-28 22:15:51 -0400
commite5019b79fd98d47162051f1ba3de57b4cb2943b5 (patch)
tree688e1a0f759f22527e298ee9d9d3f8aabe9f61ac /gi/repo.cpp
parent2b6d0fbfb61dd42d88ec83092bdbea539dda99bd (diff)
downloadgjs-e5019b79fd98d47162051f1ba3de57b4cb2943b5.tar.gz
js: Adapt to new JSClassOps struct layout
The getProperty and setProperty hooks are gone. The newEnumerate hook is moved in from JSObjectOps, and so we can change importer.cpp to use a regular old JSClass again instead of the JS Friend API version which was required in order to use JSObjectOps. See: #161
Diffstat (limited to 'gi/repo.cpp')
-rw-r--r--gi/repo.cpp14
1 files changed, 6 insertions, 8 deletions
diff --git a/gi/repo.cpp b/gi/repo.cpp
index 378bdf51..2e67bfd7 100644
--- a/gi/repo.cpp
+++ b/gi/repo.cpp
@@ -222,15 +222,13 @@ repo_finalize(JSFreeOp *fop,
* class have.
*/
static const struct JSClassOps gjs_repo_class_ops = {
- NULL, /* addProperty */
- NULL, /* deleteProperty */
- NULL, /* getProperty */
- NULL, /* setProperty */
- NULL, /* enumerate */
+ nullptr, // addProperty
+ nullptr, // deleteProperty
+ nullptr, // enumerate
+ nullptr, // newEnumerate
repo_resolve,
- nullptr, /* mayResolve */
- repo_finalize
-};
+ nullptr, // mayResolve
+ repo_finalize};
struct JSClass gjs_repo_class = {
"GIRepository", /* means "new GIRepository()" works */