Skip to content

Commit 23c065f

Browse files
committed
chore: update librime-ahk
1 parent c6198a1 commit 23c065f

File tree

3 files changed

+17
-17
lines changed

3 files changed

+17
-17
lines changed

Lib/RabbitCandidateBox.ahk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ GetCompositionText(composition, &pre_selected, &selected, &post_selected) {
3333
local preedit_buffer ; insert caret text into preedit text if applicable
3434
if 0 <= composition.cursor_pos and composition.cursor_pos <= preedit_length {
3535
preedit_buffer := Buffer(preedit_length + cursor_size, 0)
36-
local temp_preedit := c_str(preedit)
36+
local temp_preedit := RimeStruct.c_str(preedit)
3737
local src := temp_preedit.Ptr
3838
local tgt := preedit_buffer.Ptr
3939
Loop composition.cursor_pos {

Lib/RabbitMonitors.ahk

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,8 @@ class Point extends Class {
3333
}
3434

3535
static x_offset := (*) => 0
36-
static y_offset := (*) => Point.x_offset() + INT_SIZE()
37-
static struct_size := (*) => Point.y_offset() + INT_SIZE()
36+
static y_offset := (*) => Point.x_offset() + A_IntSize
37+
static struct_size := (*) => Point.y_offset() + A_IntSize
3838

3939
struct_ptr := (*) => this.buff.Ptr
4040

@@ -58,10 +58,10 @@ class Rect extends Class {
5858
}
5959

6060
static left_offset := (*) => 0
61-
static top_offset := (*) => Rect.left_offset() + INT_SIZE()
62-
static right_offset := (*) => Rect.top_offset() + INT_SIZE()
63-
static bottom_offset := (*) => Rect.right_offset() + INT_SIZE()
64-
static struct_size := (*) => Rect.bottom_offset() + INT_SIZE()
61+
static top_offset := (*) => Rect.left_offset() + A_IntSize
62+
static right_offset := (*) => Rect.top_offset() + A_IntSize
63+
static bottom_offset := (*) => Rect.right_offset() + A_IntSize
64+
static struct_size := (*) => Rect.bottom_offset() + A_IntSize
6565

6666
struct_ptr := (*) => this.buff.Ptr
6767

@@ -97,10 +97,10 @@ class MonitorInfo extends Class {
9797
}
9898

9999
static size_offset := (*) => 0
100-
static monitor_offset := (*) => MonitorInfo.size_offset() + INT_SIZE()
100+
static monitor_offset := (*) => MonitorInfo.size_offset() + A_IntSize
101101
static work_offset := (*) => MonitorInfo.monitor_offset() + Rect.struct_size()
102102
static flags_offset := (*) => MonitorInfo.work_offset() + Rect.struct_size()
103-
static struct_size := (*) => MonitorInfo.flags_offset() + INT_SIZE()
103+
static struct_size := (*) => MonitorInfo.flags_offset() + A_IntSize
104104

105105
struct_ptr := (*) => this.buff.Ptr
106106

@@ -110,17 +110,17 @@ class MonitorInfo extends Class {
110110
monitor {
111111
get => Rect(
112112
NumGet(this.struct_ptr(), MonitorInfo.monitor_offset(), "Int"),
113-
NumGet(this.struct_ptr(), MonitorInfo.monitor_offset() + INT_SIZE(), "Int"),
114-
NumGet(this.struct_ptr(), MonitorInfo.monitor_offset() + INT_SIZE() * 2, "Int"),
115-
NumGet(this.struct_ptr(), MonitorInfo.monitor_offset() + INT_SIZE() * 3, "Int")
113+
NumGet(this.struct_ptr(), MonitorInfo.monitor_offset() + A_IntSize, "Int"),
114+
NumGet(this.struct_ptr(), MonitorInfo.monitor_offset() + A_IntSize * 2, "Int"),
115+
NumGet(this.struct_ptr(), MonitorInfo.monitor_offset() + A_IntSize * 3, "Int")
116116
)
117117
}
118118
work {
119119
get => Rect(
120120
NumGet(this.struct_ptr(), MonitorInfo.work_offset(), "Int"),
121-
NumGet(this.struct_ptr(), MonitorInfo.work_offset() + INT_SIZE(), "Int"),
122-
NumGet(this.struct_ptr(), MonitorInfo.work_offset() + INT_SIZE() * 2, "Int"),
123-
NumGet(this.struct_ptr(), MonitorInfo.work_offset() + INT_SIZE() * 3, "Int")
121+
NumGet(this.struct_ptr(), MonitorInfo.work_offset() + A_IntSize, "Int"),
122+
NumGet(this.struct_ptr(), MonitorInfo.work_offset() + A_IntSize * 2, "Int"),
123+
NumGet(this.struct_ptr(), MonitorInfo.work_offset() + A_IntSize * 3, "Int")
124124
)
125125
}
126126
flags {
@@ -134,7 +134,7 @@ class MonitorInfoEx extends MonitorInfo {
134134
NumPut("Int", MonitorInfoEx.struct_size(), this.struct_ptr())
135135
}
136136

137-
static device_offset := (*) => MonitorInfoEx.flags_offset() + INT_SIZE()
137+
static device_offset := (*) => MonitorInfoEx.flags_offset() + A_IntSize
138138
static struct_size := (*) => MonitorInfoEx.device_offset() + WCHAR_SIZE() * CCHDEVICENAME
139139

140140
device {

Lib/librime-ahk

0 commit comments

Comments
 (0)