FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
flutter/engine/src/flutter/skwasm/string.cc at main · flutter/flutter · GitHub
Uh oh!
There was an error while loading.
Please reload this page
.
flutter
/
flutter
Public
Notifications
You must be signed in to change notification settings
Fork
31k
Star
179k
Code
Issues
5k+
Pull requests
645
Actions
Projects
Wiki
Security and quality
0
Insights
Additional navigation options
Code
Issues
Pull requests
Actions
Projects
Wiki
Security and quality
Insights
Expand file tree
Breadcrumbs
flutter
/
engine
/
src
/
flutter
/
skwasm
/
string.cc
Copy path
More file actions
More file actions
Latest commit
History
History
History
43 lines (34 loc) · 1.1 KB
Breadcrumbs
flutter
/
engine
/
src
/
flutter
/
skwasm
/
string.cc
Copy path
File metadata and controls
43 lines (34 loc) · 1.1 KB
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
//
Copyright 2013 The Flutter Authors. All rights reserved.
//
Use of this source code is governed by a BSD-style license that can be
//
found in the LICENSE file.
#
include
<
string
>
#
include
"
flutter/skwasm/export.h
"
#
include
"
flutter/skwasm/live_objects.h
"
#
include
"
third_party/skia/include/core/SkString.h
"
SKWASM_EXPORT
SkString*
skString_allocate
(
size_t
length) {
Skwasm::live_string_count++;
return
new
SkString
(length);
}
SKWASM_EXPORT
char
*
skString_getData
(SkString* string) {
return
string->
data
();
}
SKWASM_EXPORT
int
skString_getLength
(SkString* string) {
return
string->
size
();
}
SKWASM_EXPORT
void
skString_free
(SkString* string) {
Skwasm::live_string_count--;
return
delete
string;
}
SKWASM_EXPORT
std::u16string*
skString16_allocate
(
size_t
length) {
Skwasm::live_string16_count++;
std::u16string* string =
new
std::u16string
();
string->
resize
(length);
return
string;
}
SKWASM_EXPORT
char16_t
*
skString16_getData
(std::u16string* string) {
return
string->
data
();
}
SKWASM_EXPORT
void
skString16_free
(std::u16string* string) {
Skwasm::live_string16_count--;
delete
string;
}
Back
|
FazBrowse Home
|
New Git URL