mirror of
https://github.com/DreamMaoMao/maomaowm.git
synced 2026-05-02 06:46:29 -04:00
Translate final Chinese comments in mango.c and parse_config.h
Co-authored-by: squassina <8495707+squassina@users.noreply.github.com>
This commit is contained in:
parent
ffa83cd0fc
commit
3f0c11b068
2 changed files with 18 additions and 14 deletions
|
|
@ -1485,8 +1485,9 @@ bool parse_option(Config *config, char *key, char *value) {
|
|||
"scroller_proportion_preset format: %s\n",
|
||||
value);
|
||||
free(value_copy);
|
||||
free(config->scroller_proportion_preset); // 释放已分配的内存
|
||||
config->scroller_proportion_preset = NULL; // 防止野指针
|
||||
free(config->scroller_proportion_preset); // Free allocated memory
|
||||
config->scroller_proportion_preset =
|
||||
NULL; // Prevent dangling pointer
|
||||
config->scroller_proportion_preset_count = 0;
|
||||
return false;
|
||||
}
|
||||
|
|
@ -3265,16 +3266,18 @@ void set_value_default() {
|
|||
|
||||
/* appearance */
|
||||
config.axis_bind_apply_timeout =
|
||||
axis_bind_apply_timeout; // 滚轮绑定动作的触发的时间间隔
|
||||
config.focus_on_activate =
|
||||
focus_on_activate; // 收到窗口激活请求是否自动跳转聚焦
|
||||
config.new_is_master = new_is_master; // 新窗口是否插在头部
|
||||
config.default_mfact = default_mfact; // master 窗口比例
|
||||
config.default_nmaster = default_nmaster; // 默认master数量
|
||||
axis_bind_apply_timeout; // Timeout interval for mouse wheel binding
|
||||
// actions
|
||||
config.focus_on_activate = focus_on_activate; // Auto-focus when receiving
|
||||
// window activation request
|
||||
config.new_is_master = new_is_master; // Insert new windows at the head
|
||||
config.default_mfact = default_mfact; // Master window proportion
|
||||
config.default_nmaster =
|
||||
default_nmaster; // Default number of master windows
|
||||
config.center_master_overspread =
|
||||
center_master_overspread; // 中心master时是否铺满
|
||||
center_master_overspread; // Whether to fill screen when center master
|
||||
config.center_when_single_stack =
|
||||
center_when_single_stack; // 单个stack时是否居中
|
||||
center_when_single_stack; // Whether to center when single stack window
|
||||
|
||||
config.numlockon = numlockon; // Enable numlock
|
||||
|
||||
|
|
|
|||
|
|
@ -274,8 +274,8 @@ typedef struct {
|
|||
struct wl_list link;
|
||||
struct wlr_input_device *wlr_device;
|
||||
struct libinput_device *libinput_device;
|
||||
struct wl_listener destroy_listener; // 用于监听设备销毁事件
|
||||
void *device_data; // 新增:指向设备特定数据(如 Switch)
|
||||
struct wl_listener destroy_listener; // Listen for device destruction events
|
||||
void *device_data; // Added: pointer to device-specific data (e.g. Switch)
|
||||
} InputDevice;
|
||||
|
||||
typedef struct {
|
||||
|
|
@ -586,8 +586,9 @@ static void pinch_end(struct wl_listener *listener, void *data);
|
|||
static void hold_begin(struct wl_listener *listener, void *data);
|
||||
static void hold_end(struct wl_listener *listener, void *data);
|
||||
static void checkidleinhibitor(struct wlr_surface *exclude);
|
||||
static void cleanup(void); // 退出清理
|
||||
static void cleanupmon(struct wl_listener *listener, void *data); // 退出清理
|
||||
static void cleanup(void); // Cleanup on exit
|
||||
static void cleanupmon(struct wl_listener *listener,
|
||||
void *data); // Monitor cleanup
|
||||
static void closemon(Monitor *m);
|
||||
static void cleanuplisteners(void);
|
||||
static void toggle_hotarea(int32_t x_root, int32_t y_root); // 触发热区
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue