mirror of
https://github.com/wgh136/flutter_qjs.git
synced 2025-09-27 05:27:23 +00:00
revert 4ea1e95
This commit is contained in:
@@ -27,14 +27,9 @@ abstract class JSRef {
|
||||
_refCount++;
|
||||
}
|
||||
|
||||
bool _released = false;
|
||||
|
||||
void free() {
|
||||
_refCount--;
|
||||
if (_refCount < 0 && !_released){
|
||||
_released = true;
|
||||
destroy();
|
||||
}
|
||||
if (_refCount < 0) destroy();
|
||||
}
|
||||
|
||||
void destroy();
|
||||
|
Reference in New Issue
Block a user