Flutter Engine
The Flutter Engine
Toggle main menu visibility
Main Page
Related Pages
Modules
Namespaces
Namespace List
Namespace Members
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
y
Enumerations
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
Enumerator
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Classes
Class List
Class Index
Class Hierarchy
Class Members
All
:
[
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Functions
[
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
Enumerations
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Enumerator
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
y
Properties
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
z
Related Functions
:
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
r
s
t
u
v
w
y
z
Files
File List
File Members
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Enumerations
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
r
s
t
v
w
y
Enumerator
b
c
d
e
f
g
h
k
l
m
n
p
r
s
t
u
v
w
Macros
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Modules
Pages
flow
testing
gl_context_switch_test.cc
Go to the documentation of this file.
1
// Copyright 2013 The Flutter Authors. All rights reserved.
2
// Use of this source code is governed by a BSD-style license that can be
3
// found in the LICENSE file.
4
5
#include "
gl_context_switch_test.h
"
6
7
namespace
flutter
{
8
namespace
testing {
9
10
static
thread_local
std::unique_ptr<int>
current_context
;
11
12
TestSwitchableGLContext::TestSwitchableGLContext
(
int
context)
13
: context_(context){};
14
15
TestSwitchableGLContext::~TestSwitchableGLContext
() =
default
;
16
17
bool
TestSwitchableGLContext::SetCurrent
() {
18
SetCurrentContext
(context_);
19
return
true
;
20
};
21
22
bool
TestSwitchableGLContext::RemoveCurrent
() {
23
SetCurrentContext
(-1);
24
return
true
;
25
};
26
27
int
TestSwitchableGLContext::GetContext
() {
28
return
context_;
29
};
30
31
int
TestSwitchableGLContext::GetCurrentContext
() {
32
return
*(
current_context
.get());
33
};
34
35
void
TestSwitchableGLContext::SetCurrentContext
(
int
context) {
36
current_context
.reset(
new
int
(context));
37
};
38
}
// namespace testing
39
}
// namespace flutter
flutter::testing::TestSwitchableGLContext::SetCurrent
bool SetCurrent() override
Definition:
gl_context_switch_test.cc:17
flutter::testing::TestSwitchableGLContext::TestSwitchableGLContext
TestSwitchableGLContext(int context)
Definition:
gl_context_switch_test.cc:12
flutter::testing::TestSwitchableGLContext::GetContext
int GetContext()
Definition:
gl_context_switch_test.cc:27
flutter::testing::TestSwitchableGLContext::GetCurrentContext
static int GetCurrentContext()
Definition:
gl_context_switch_test.cc:31
flutter::testing::TestSwitchableGLContext::SetCurrentContext
static void SetCurrentContext(int context)
Definition:
gl_context_switch_test.cc:35
flutter::testing::TestSwitchableGLContext::RemoveCurrent
bool RemoveCurrent() override
Definition:
gl_context_switch_test.cc:22
flutter::testing::TestSwitchableGLContext::~TestSwitchableGLContext
~TestSwitchableGLContext() override
gl_context_switch_test.h
flutter::testing::current_context
static thread_local std::unique_ptr< int > current_context
Definition:
gl_context_switch_test.cc:10
flutter
Definition:
asset_manager.cc:10
Generated on Sun Jun 23 2024 21:54:57 for Flutter Engine by
1.9.4