@girs/bamf-3 3.0.0-4.0.0-beta.40 → 3.0.0-4.0.0-beta.41
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/bamf-3.d.ts +373 -46
- package/package.json +4 -4
- package/tsconfig.json +12 -1
- package/typedoc.json +3 -1
package/README.md
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|

|
|
6
6
|
|
|
7
7
|
|
|
8
|
-
GJS TypeScript type definitions for Bamf-3, generated from library version 3.0.0 using [ts-for-gir](https://github.com/gjsify/ts-for-gir) v4.0.0-beta.
|
|
8
|
+
GJS TypeScript type definitions for Bamf-3, generated from library version 3.0.0 using [ts-for-gir](https://github.com/gjsify/ts-for-gir) v4.0.0-beta.41.
|
|
9
9
|
|
|
10
10
|
## Install
|
|
11
11
|
|
package/bamf-3.d.ts
CHANGED
|
@@ -18,6 +18,9 @@ export namespace Bamf {
|
|
|
18
18
|
* Bamf-3
|
|
19
19
|
*/
|
|
20
20
|
|
|
21
|
+
/**
|
|
22
|
+
* @gir-type Enum
|
|
23
|
+
*/
|
|
21
24
|
enum ClickBehavior {
|
|
22
25
|
NONE,
|
|
23
26
|
OPEN,
|
|
@@ -29,6 +32,9 @@ export namespace Bamf {
|
|
|
29
32
|
PICKER,
|
|
30
33
|
}
|
|
31
34
|
|
|
35
|
+
/**
|
|
36
|
+
* @gir-type Enum
|
|
37
|
+
*/
|
|
32
38
|
enum WindowMaximizationType {
|
|
33
39
|
FLOATING,
|
|
34
40
|
HORIZONTAL_MAXIMIZED,
|
|
@@ -36,6 +42,9 @@ export namespace Bamf {
|
|
|
36
42
|
MAXIMIZED,
|
|
37
43
|
}
|
|
38
44
|
|
|
45
|
+
/**
|
|
46
|
+
* @gir-type Enum
|
|
47
|
+
*/
|
|
39
48
|
enum WindowType {
|
|
40
49
|
NORMAL,
|
|
41
50
|
DESKTOP,
|
|
@@ -69,14 +78,26 @@ export namespace Bamf {
|
|
|
69
78
|
const VIEW_SIGNAL_USER_VISIBLE_CHANGED: string;
|
|
70
79
|
const WINDOW_SIGNAL_MAXIMIZED_CHANGED: string;
|
|
71
80
|
const WINDOW_SIGNAL_MONITOR_CHANGED: string;
|
|
81
|
+
/**
|
|
82
|
+
* @gir-type Callback
|
|
83
|
+
*/
|
|
72
84
|
interface TabPreviewReadyCallback {
|
|
73
85
|
(self: Tab, preview_data: string): void;
|
|
74
86
|
}
|
|
75
87
|
namespace Application {
|
|
76
88
|
// Signal signatures
|
|
77
89
|
interface SignalSignatures extends View.SignalSignatures {
|
|
90
|
+
/**
|
|
91
|
+
* @signal
|
|
92
|
+
*/
|
|
78
93
|
'desktop-file-updated': (arg0: string) => void;
|
|
94
|
+
/**
|
|
95
|
+
* @signal
|
|
96
|
+
*/
|
|
79
97
|
'window-added': (arg0: Window) => void;
|
|
98
|
+
/**
|
|
99
|
+
* @signal
|
|
100
|
+
*/
|
|
80
101
|
'window-removed': (arg0: Window) => void;
|
|
81
102
|
'notify::active': (pspec: GObject.ParamSpec) => void;
|
|
82
103
|
'notify::path': (pspec: GObject.ParamSpec) => void;
|
|
@@ -91,6 +112,9 @@ export namespace Bamf {
|
|
|
91
112
|
interface ConstructorProps extends View.ConstructorProps {}
|
|
92
113
|
}
|
|
93
114
|
|
|
115
|
+
/**
|
|
116
|
+
* @gir-type Class
|
|
117
|
+
*/
|
|
94
118
|
class Application extends View {
|
|
95
119
|
static $gtype: GObject.GType<Application>;
|
|
96
120
|
|
|
@@ -111,16 +135,19 @@ export namespace Bamf {
|
|
|
111
135
|
|
|
112
136
|
// Signals
|
|
113
137
|
|
|
138
|
+
/** @signal */
|
|
114
139
|
connect<K extends keyof Application.SignalSignatures>(
|
|
115
140
|
signal: K,
|
|
116
141
|
callback: GObject.SignalCallback<this, Application.SignalSignatures[K]>,
|
|
117
142
|
): number;
|
|
118
143
|
connect(signal: string, callback: (...args: any[]) => any): number;
|
|
144
|
+
/** @signal */
|
|
119
145
|
connect_after<K extends keyof Application.SignalSignatures>(
|
|
120
146
|
signal: K,
|
|
121
147
|
callback: GObject.SignalCallback<this, Application.SignalSignatures[K]>,
|
|
122
148
|
): number;
|
|
123
149
|
connect_after(signal: string, callback: (...args: any[]) => any): number;
|
|
150
|
+
/** @signal */
|
|
124
151
|
emit<K extends keyof Application.SignalSignatures>(
|
|
125
152
|
signal: K,
|
|
126
153
|
...args: GObject.GjsParameters<Application.SignalSignatures[K]> extends [any, ...infer Q] ? Q : never
|
|
@@ -131,7 +158,7 @@ export namespace Bamf {
|
|
|
131
158
|
|
|
132
159
|
/**
|
|
133
160
|
* Used to fetch the bus name and the object path of the remote application menu.
|
|
134
|
-
* @returns
|
|
161
|
+
* @returns `true` if found, `false` otherwise.
|
|
135
162
|
*/
|
|
136
163
|
get_application_menu(): [boolean, string, string];
|
|
137
164
|
get_application_type(): string;
|
|
@@ -141,26 +168,32 @@ export namespace Bamf {
|
|
|
141
168
|
* @returns A string representing the path to the desktop file.
|
|
142
169
|
*/
|
|
143
170
|
get_desktop_file(): string;
|
|
171
|
+
/**
|
|
172
|
+
* @returns The focusable child for this application.
|
|
173
|
+
*/
|
|
144
174
|
get_focusable_child(): View;
|
|
145
175
|
/**
|
|
146
176
|
* Used to discover whether the application wants menu stubs shown.
|
|
147
177
|
* @returns Whether the stubs should be shown.
|
|
148
178
|
*/
|
|
149
179
|
get_show_menu_stubs(): boolean;
|
|
180
|
+
/**
|
|
181
|
+
* @returns A string array containing the supported mime-types.
|
|
182
|
+
*/
|
|
150
183
|
get_supported_mime_types(): string[];
|
|
151
184
|
/**
|
|
152
185
|
* Used to fetch the application contains a Window with given `xid`.
|
|
153
186
|
* @param xid an X11 Window ID
|
|
154
|
-
* @returns a
|
|
187
|
+
* @returns a {@link Bamf.Window} for the passed `xid` or `null` if not found.
|
|
155
188
|
*/
|
|
156
189
|
get_window_for_xid(xid: number): Window;
|
|
157
190
|
/**
|
|
158
|
-
* Used to fetch all
|
|
159
|
-
* @returns A list of
|
|
191
|
+
* Used to fetch all {@link Bamf.Window}'s associated with the passed {@link Bamf.Application}.
|
|
192
|
+
* @returns A list of {@link Bamf.Window}'s.
|
|
160
193
|
*/
|
|
161
194
|
get_windows(): Window[];
|
|
162
195
|
/**
|
|
163
|
-
* Used to fetch all
|
|
196
|
+
* Used to fetch all {@link Bamf.Window}'s xids associated with the passed {@link Bamf.Application}.
|
|
164
197
|
* @returns An array of xids.
|
|
165
198
|
*/
|
|
166
199
|
get_xids(): number[];
|
|
@@ -175,6 +208,9 @@ export namespace Bamf {
|
|
|
175
208
|
interface ConstructorProps extends GObject.Object.ConstructorProps {}
|
|
176
209
|
}
|
|
177
210
|
|
|
211
|
+
/**
|
|
212
|
+
* @gir-type Class
|
|
213
|
+
*/
|
|
178
214
|
class Control extends GObject.Object {
|
|
179
215
|
static $gtype: GObject.GType<Control>;
|
|
180
216
|
|
|
@@ -195,16 +231,19 @@ export namespace Bamf {
|
|
|
195
231
|
|
|
196
232
|
// Signals
|
|
197
233
|
|
|
234
|
+
/** @signal */
|
|
198
235
|
connect<K extends keyof Control.SignalSignatures>(
|
|
199
236
|
signal: K,
|
|
200
237
|
callback: GObject.SignalCallback<this, Control.SignalSignatures[K]>,
|
|
201
238
|
): number;
|
|
202
239
|
connect(signal: string, callback: (...args: any[]) => any): number;
|
|
240
|
+
/** @signal */
|
|
203
241
|
connect_after<K extends keyof Control.SignalSignatures>(
|
|
204
242
|
signal: K,
|
|
205
243
|
callback: GObject.SignalCallback<this, Control.SignalSignatures[K]>,
|
|
206
244
|
): number;
|
|
207
245
|
connect_after(signal: string, callback: (...args: any[]) => any): number;
|
|
246
|
+
/** @signal */
|
|
208
247
|
emit<K extends keyof Control.SignalSignatures>(
|
|
209
248
|
signal: K,
|
|
210
249
|
...args: GObject.GjsParameters<Control.SignalSignatures[K]> extends [any, ...infer Q] ? Q : never
|
|
@@ -217,19 +256,47 @@ export namespace Bamf {
|
|
|
217
256
|
|
|
218
257
|
// Methods
|
|
219
258
|
|
|
259
|
+
/**
|
|
260
|
+
* @param application
|
|
261
|
+
*/
|
|
220
262
|
create_local_desktop_file(application: Application): void;
|
|
263
|
+
/**
|
|
264
|
+
* @param desktop_file
|
|
265
|
+
*/
|
|
221
266
|
insert_desktop_file(desktop_file: string): void;
|
|
267
|
+
/**
|
|
268
|
+
* @param desktop_file
|
|
269
|
+
* @param pid
|
|
270
|
+
*/
|
|
222
271
|
register_application_for_pid(desktop_file: string, pid: number): void;
|
|
272
|
+
/**
|
|
273
|
+
* @param behavior
|
|
274
|
+
*/
|
|
223
275
|
set_approver_behavior(behavior: number): void;
|
|
224
276
|
}
|
|
225
277
|
|
|
226
278
|
namespace Matcher {
|
|
227
279
|
// Signal signatures
|
|
228
280
|
interface SignalSignatures extends GObject.Object.SignalSignatures {
|
|
281
|
+
/**
|
|
282
|
+
* @signal
|
|
283
|
+
*/
|
|
229
284
|
'active-application-changed': (arg0: Application, arg1: Application) => void;
|
|
285
|
+
/**
|
|
286
|
+
* @signal
|
|
287
|
+
*/
|
|
230
288
|
'active-window-changed': (arg0: Window, arg1: Window) => void;
|
|
289
|
+
/**
|
|
290
|
+
* @signal
|
|
291
|
+
*/
|
|
231
292
|
'stacking-order-changed': () => void;
|
|
293
|
+
/**
|
|
294
|
+
* @signal
|
|
295
|
+
*/
|
|
232
296
|
'view-closed': (arg0: View) => void;
|
|
297
|
+
/**
|
|
298
|
+
* @signal
|
|
299
|
+
*/
|
|
233
300
|
'view-opened': (arg0: View) => void;
|
|
234
301
|
}
|
|
235
302
|
|
|
@@ -238,6 +305,9 @@ export namespace Bamf {
|
|
|
238
305
|
interface ConstructorProps extends GObject.Object.ConstructorProps {}
|
|
239
306
|
}
|
|
240
307
|
|
|
308
|
+
/**
|
|
309
|
+
* @gir-type Class
|
|
310
|
+
*/
|
|
241
311
|
class Matcher extends GObject.Object {
|
|
242
312
|
static $gtype: GObject.GType<Matcher>;
|
|
243
313
|
|
|
@@ -258,16 +328,19 @@ export namespace Bamf {
|
|
|
258
328
|
|
|
259
329
|
// Signals
|
|
260
330
|
|
|
331
|
+
/** @signal */
|
|
261
332
|
connect<K extends keyof Matcher.SignalSignatures>(
|
|
262
333
|
signal: K,
|
|
263
334
|
callback: GObject.SignalCallback<this, Matcher.SignalSignatures[K]>,
|
|
264
335
|
): number;
|
|
265
336
|
connect(signal: string, callback: (...args: any[]) => any): number;
|
|
337
|
+
/** @signal */
|
|
266
338
|
connect_after<K extends keyof Matcher.SignalSignatures>(
|
|
267
339
|
signal: K,
|
|
268
340
|
callback: GObject.SignalCallback<this, Matcher.SignalSignatures[K]>,
|
|
269
341
|
): number;
|
|
270
342
|
connect_after(signal: string, callback: (...args: any[]) => any): number;
|
|
343
|
+
/** @signal */
|
|
271
344
|
emit<K extends keyof Matcher.SignalSignatures>(
|
|
272
345
|
signal: K,
|
|
273
346
|
...args: GObject.GjsParameters<Matcher.SignalSignatures[K]> extends [any, ...infer Q] ? Q : never
|
|
@@ -283,52 +356,60 @@ export namespace Bamf {
|
|
|
283
356
|
|
|
284
357
|
// Methods
|
|
285
358
|
|
|
359
|
+
/**
|
|
360
|
+
* @param desktop_file
|
|
361
|
+
*/
|
|
286
362
|
application_is_running(desktop_file: string): boolean;
|
|
287
363
|
/**
|
|
288
|
-
* Used to fetch the active
|
|
289
|
-
* @returns The active
|
|
364
|
+
* Used to fetch the active {@link Bamf.Application}.
|
|
365
|
+
* @returns The active {@link Bamf.Application}.
|
|
290
366
|
*/
|
|
291
367
|
get_active_application(): Application;
|
|
292
368
|
/**
|
|
293
|
-
* Used to fetch the active
|
|
294
|
-
* @returns The active
|
|
369
|
+
* Used to fetch the active {@link Bamf.Window}.
|
|
370
|
+
* @returns The active {@link Bamf.Window}.
|
|
295
371
|
*/
|
|
296
372
|
get_active_window(): Window;
|
|
373
|
+
/**
|
|
374
|
+
* @param desktop_file_path Path to the desktop file
|
|
375
|
+
* @param create_if_not_found Create a {@link Bamf.Application} if one isn't found
|
|
376
|
+
* @returns A {@link Bamf.Application} for given desktop file.
|
|
377
|
+
*/
|
|
297
378
|
get_application_for_desktop_file(desktop_file_path: string, create_if_not_found: boolean): Application;
|
|
298
379
|
/**
|
|
299
|
-
* Used to fetch the
|
|
380
|
+
* Used to fetch the {@link Bamf.Application} containing the passed window.
|
|
300
381
|
* @param window The window to look for
|
|
301
|
-
* @returns The
|
|
382
|
+
* @returns The {@link Bamf.Application} representing the xid passed, or NULL if none exists.
|
|
302
383
|
*/
|
|
303
384
|
get_application_for_window(window: Window): Application;
|
|
304
385
|
/**
|
|
305
|
-
* Used to fetch the
|
|
386
|
+
* Used to fetch the {@link Bamf.Application} containing the passed xid.
|
|
306
387
|
* @param xid The XID to search for
|
|
307
|
-
* @returns The
|
|
388
|
+
* @returns The {@link Bamf.Application} representing the xid passed, or NULL if none exists.
|
|
308
389
|
*/
|
|
309
390
|
get_application_for_xid(xid: number): Application;
|
|
310
391
|
/**
|
|
311
|
-
* Used to fetch all
|
|
392
|
+
* Used to fetch all {@link Bamf.Application}'s running or not. Application authors who wish to only
|
|
312
393
|
* see running applications should use bamf_matcher_get_running_applications instead. The reason
|
|
313
394
|
* this method is needed is bamf will occasionally track applications which are not currently
|
|
314
395
|
* running for nefarious purposes.
|
|
315
|
-
* @returns A list of
|
|
396
|
+
* @returns A list of {@link Bamf.Application}'s.
|
|
316
397
|
*/
|
|
317
398
|
get_applications(): Application[];
|
|
318
399
|
/**
|
|
319
|
-
* Used to fetch all
|
|
320
|
-
* @returns A list of
|
|
400
|
+
* Used to fetch all {@link Bamf.Application}'s which are running.
|
|
401
|
+
* @returns A list of {@link Bamf.Application}'s.
|
|
321
402
|
*/
|
|
322
403
|
get_running_applications(): Application[];
|
|
323
404
|
/**
|
|
324
|
-
* Used to fetch all
|
|
325
|
-
* @returns A list of
|
|
405
|
+
* Used to fetch all {@link Bamf.View}'s representing tabs. Currently unused.
|
|
406
|
+
* @returns A list of {@link Bamf.Tab}'s.
|
|
326
407
|
*/
|
|
327
408
|
get_tabs(): Tab[];
|
|
328
409
|
/**
|
|
329
|
-
* Used to fetch the
|
|
410
|
+
* Used to fetch the {@link Bamf.Window} that wraps the given `window`.
|
|
330
411
|
* @param xid The X11 Window ID to search for
|
|
331
|
-
* @returns The
|
|
412
|
+
* @returns The {@link Bamf.Window} representing the xid passed, or NULL if none exists.
|
|
332
413
|
*/
|
|
333
414
|
get_window_for_xid(xid: number): Window;
|
|
334
415
|
/**
|
|
@@ -336,12 +417,12 @@ export namespace Bamf {
|
|
|
336
417
|
* in stacking bottom-to-top order. If the `monitor` is set to a negative value,
|
|
337
418
|
* then it fetches all the available windows in all monitors.
|
|
338
419
|
* @param monitor the monitor you want the stack from, negative value to get all
|
|
339
|
-
* @returns A list of
|
|
420
|
+
* @returns A list of {@link Bamf.Window}'s.
|
|
340
421
|
*/
|
|
341
422
|
get_window_stack_for_monitor(monitor: number): Window[];
|
|
342
423
|
/**
|
|
343
424
|
* Used to fetch all windows that BAMF knows about.
|
|
344
|
-
* @returns A list of
|
|
425
|
+
* @returns A list of {@link Bamf.Window}'s.
|
|
345
426
|
*/
|
|
346
427
|
get_windows(): Window[];
|
|
347
428
|
/**
|
|
@@ -385,16 +466,37 @@ export namespace Bamf {
|
|
|
385
466
|
}
|
|
386
467
|
}
|
|
387
468
|
|
|
469
|
+
/**
|
|
470
|
+
* @gir-type Class
|
|
471
|
+
*/
|
|
388
472
|
class Tab extends View {
|
|
389
473
|
static $gtype: GObject.GType<Tab>;
|
|
390
474
|
|
|
391
475
|
// Properties
|
|
392
476
|
|
|
477
|
+
/**
|
|
478
|
+
* @read-only
|
|
479
|
+
*/
|
|
393
480
|
get desktop_id(): string;
|
|
481
|
+
/**
|
|
482
|
+
* @read-only
|
|
483
|
+
*/
|
|
394
484
|
get desktopId(): string;
|
|
485
|
+
/**
|
|
486
|
+
* @read-only
|
|
487
|
+
*/
|
|
395
488
|
get is_foreground_tab(): boolean;
|
|
489
|
+
/**
|
|
490
|
+
* @read-only
|
|
491
|
+
*/
|
|
396
492
|
get isForegroundTab(): boolean;
|
|
493
|
+
/**
|
|
494
|
+
* @read-only
|
|
495
|
+
*/
|
|
397
496
|
get location(): string;
|
|
497
|
+
/**
|
|
498
|
+
* @read-only
|
|
499
|
+
*/
|
|
398
500
|
get xid(): number;
|
|
399
501
|
|
|
400
502
|
/**
|
|
@@ -414,16 +516,19 @@ export namespace Bamf {
|
|
|
414
516
|
|
|
415
517
|
// Signals
|
|
416
518
|
|
|
519
|
+
/** @signal */
|
|
417
520
|
connect<K extends keyof Tab.SignalSignatures>(
|
|
418
521
|
signal: K,
|
|
419
522
|
callback: GObject.SignalCallback<this, Tab.SignalSignatures[K]>,
|
|
420
523
|
): number;
|
|
421
524
|
connect(signal: string, callback: (...args: any[]) => any): number;
|
|
525
|
+
/** @signal */
|
|
422
526
|
connect_after<K extends keyof Tab.SignalSignatures>(
|
|
423
527
|
signal: K,
|
|
424
528
|
callback: GObject.SignalCallback<this, Tab.SignalSignatures[K]>,
|
|
425
529
|
): number;
|
|
426
530
|
connect_after(signal: string, callback: (...args: any[]) => any): number;
|
|
531
|
+
/** @signal */
|
|
427
532
|
emit<K extends keyof Tab.SignalSignatures>(
|
|
428
533
|
signal: K,
|
|
429
534
|
...args: GObject.GjsParameters<Tab.SignalSignatures[K]> extends [any, ...infer Q] ? Q : never
|
|
@@ -434,12 +539,20 @@ export namespace Bamf {
|
|
|
434
539
|
|
|
435
540
|
/**
|
|
436
541
|
* Returns the desktop file for the tab.
|
|
542
|
+
* @virtual
|
|
437
543
|
*/
|
|
438
544
|
vfunc_get_desktop_name(): string;
|
|
545
|
+
/**
|
|
546
|
+
* @virtual
|
|
547
|
+
*/
|
|
439
548
|
vfunc_get_is_foreground_tab(): boolean;
|
|
549
|
+
/**
|
|
550
|
+
* @virtual
|
|
551
|
+
*/
|
|
440
552
|
vfunc_get_location(): string;
|
|
441
553
|
/**
|
|
442
554
|
* The desktop file for the tab.
|
|
555
|
+
* @virtual
|
|
443
556
|
*/
|
|
444
557
|
vfunc_get_xid(): number;
|
|
445
558
|
|
|
@@ -447,14 +560,17 @@ export namespace Bamf {
|
|
|
447
560
|
|
|
448
561
|
/**
|
|
449
562
|
* Closes the selected `self` tab.
|
|
450
|
-
* @returns
|
|
563
|
+
* @returns `true` if success, `false` otherwise.
|
|
451
564
|
*/
|
|
452
565
|
close(): boolean;
|
|
453
566
|
/**
|
|
454
567
|
* Returns the desktop file for the tab.
|
|
455
|
-
* @returns The tab desktop id or
|
|
568
|
+
* @returns The tab desktop id or `null` if not set or available. Do not free the returned value, it belongs to `self`.
|
|
456
569
|
*/
|
|
457
570
|
get_desktop_name(): string;
|
|
571
|
+
/**
|
|
572
|
+
* @returns `true` if the tab is the active one on parent window XID, `false` otherwise.
|
|
573
|
+
*/
|
|
458
574
|
get_is_foreground_tab(): boolean;
|
|
459
575
|
get_location(): string;
|
|
460
576
|
/**
|
|
@@ -464,25 +580,70 @@ export namespace Bamf {
|
|
|
464
580
|
get_xid(): number;
|
|
465
581
|
/**
|
|
466
582
|
* Selects the `self` tab in the parent window.
|
|
467
|
-
* @returns
|
|
583
|
+
* @returns `true` if success, `false` otherwise.
|
|
468
584
|
*/
|
|
469
585
|
raise(): boolean;
|
|
586
|
+
/**
|
|
587
|
+
* @param callback a callback function to call when the result is ready
|
|
588
|
+
*/
|
|
470
589
|
request_preview(callback: TabPreviewReadyCallback): void;
|
|
471
590
|
}
|
|
472
591
|
|
|
473
592
|
namespace View {
|
|
474
593
|
// Signal signatures
|
|
475
594
|
interface SignalSignatures extends GObject.InitiallyUnowned.SignalSignatures {
|
|
595
|
+
/**
|
|
596
|
+
* @signal
|
|
597
|
+
* @run-first
|
|
598
|
+
*/
|
|
476
599
|
'active-changed': (arg0: boolean) => void;
|
|
600
|
+
/**
|
|
601
|
+
* @signal
|
|
602
|
+
* @run-first
|
|
603
|
+
*/
|
|
477
604
|
'child-added': (arg0: View) => void;
|
|
605
|
+
/**
|
|
606
|
+
* @signal
|
|
607
|
+
* @run-first
|
|
608
|
+
*/
|
|
478
609
|
'child-moved': (arg0: View) => void;
|
|
610
|
+
/**
|
|
611
|
+
* @signal
|
|
612
|
+
* @run-first
|
|
613
|
+
*/
|
|
479
614
|
'child-removed': (arg0: View) => void;
|
|
615
|
+
/**
|
|
616
|
+
* @signal
|
|
617
|
+
* @run-last
|
|
618
|
+
*/
|
|
480
619
|
closed: () => void;
|
|
620
|
+
/**
|
|
621
|
+
* @signal
|
|
622
|
+
*/
|
|
481
623
|
'icon-changed': (arg0: string) => void;
|
|
624
|
+
/**
|
|
625
|
+
* @signal
|
|
626
|
+
*/
|
|
482
627
|
'name-changed': (arg0: string, arg1: string) => void;
|
|
628
|
+
/**
|
|
629
|
+
* @signal
|
|
630
|
+
* @run-first
|
|
631
|
+
*/
|
|
483
632
|
'running-changed': (arg0: boolean) => void;
|
|
633
|
+
/**
|
|
634
|
+
* @signal
|
|
635
|
+
* @run-first
|
|
636
|
+
*/
|
|
484
637
|
'starting-changed': (arg0: boolean) => void;
|
|
638
|
+
/**
|
|
639
|
+
* @signal
|
|
640
|
+
* @run-first
|
|
641
|
+
*/
|
|
485
642
|
'urgent-changed': (arg0: boolean) => void;
|
|
643
|
+
/**
|
|
644
|
+
* @signal
|
|
645
|
+
* @run-first
|
|
646
|
+
*/
|
|
486
647
|
'user-visible-changed': (arg0: boolean) => void;
|
|
487
648
|
'notify::active': (pspec: GObject.ParamSpec) => void;
|
|
488
649
|
'notify::path': (pspec: GObject.ParamSpec) => void;
|
|
@@ -505,17 +666,41 @@ export namespace Bamf {
|
|
|
505
666
|
}
|
|
506
667
|
}
|
|
507
668
|
|
|
669
|
+
/**
|
|
670
|
+
* @gir-type Class
|
|
671
|
+
*/
|
|
508
672
|
class View extends GObject.InitiallyUnowned {
|
|
509
673
|
static $gtype: GObject.GType<View>;
|
|
510
674
|
|
|
511
675
|
// Properties
|
|
512
676
|
|
|
677
|
+
/**
|
|
678
|
+
* @read-only
|
|
679
|
+
*/
|
|
513
680
|
get active(): boolean;
|
|
681
|
+
/**
|
|
682
|
+
* @read-only
|
|
683
|
+
*/
|
|
514
684
|
get path(): string;
|
|
685
|
+
/**
|
|
686
|
+
* @read-only
|
|
687
|
+
*/
|
|
515
688
|
get running(): boolean;
|
|
689
|
+
/**
|
|
690
|
+
* @read-only
|
|
691
|
+
*/
|
|
516
692
|
get starting(): boolean;
|
|
693
|
+
/**
|
|
694
|
+
* @read-only
|
|
695
|
+
*/
|
|
517
696
|
get urgent(): boolean;
|
|
697
|
+
/**
|
|
698
|
+
* @read-only
|
|
699
|
+
*/
|
|
518
700
|
get user_visible(): boolean;
|
|
701
|
+
/**
|
|
702
|
+
* @read-only
|
|
703
|
+
*/
|
|
519
704
|
get userVisible(): boolean;
|
|
520
705
|
|
|
521
706
|
/**
|
|
@@ -535,16 +720,19 @@ export namespace Bamf {
|
|
|
535
720
|
|
|
536
721
|
// Signals
|
|
537
722
|
|
|
723
|
+
/** @signal */
|
|
538
724
|
connect<K extends keyof View.SignalSignatures>(
|
|
539
725
|
signal: K,
|
|
540
726
|
callback: GObject.SignalCallback<this, View.SignalSignatures[K]>,
|
|
541
727
|
): number;
|
|
542
728
|
connect(signal: string, callback: (...args: any[]) => any): number;
|
|
729
|
+
/** @signal */
|
|
543
730
|
connect_after<K extends keyof View.SignalSignatures>(
|
|
544
731
|
signal: K,
|
|
545
732
|
callback: GObject.SignalCallback<this, View.SignalSignatures[K]>,
|
|
546
733
|
): number;
|
|
547
734
|
connect_after(signal: string, callback: (...args: any[]) => any): number;
|
|
735
|
+
/** @signal */
|
|
548
736
|
emit<K extends keyof View.SignalSignatures>(
|
|
549
737
|
signal: K,
|
|
550
738
|
...args: GObject.GjsParameters<View.SignalSignatures[K]> extends [any, ...infer Q] ? Q : never
|
|
@@ -553,52 +741,118 @@ export namespace Bamf {
|
|
|
553
741
|
|
|
554
742
|
// Virtual methods
|
|
555
743
|
|
|
744
|
+
/**
|
|
745
|
+
* @param active
|
|
746
|
+
* @virtual
|
|
747
|
+
*/
|
|
556
748
|
vfunc_active_changed(active: boolean): void;
|
|
749
|
+
/**
|
|
750
|
+
* @param child
|
|
751
|
+
* @virtual
|
|
752
|
+
*/
|
|
557
753
|
vfunc_child_added(child: View): void;
|
|
754
|
+
/**
|
|
755
|
+
* @param child
|
|
756
|
+
* @virtual
|
|
757
|
+
*/
|
|
558
758
|
vfunc_child_moved(child: View): void;
|
|
759
|
+
/**
|
|
760
|
+
* @param child
|
|
761
|
+
* @virtual
|
|
762
|
+
*/
|
|
559
763
|
vfunc_child_removed(child: View): void;
|
|
764
|
+
/**
|
|
765
|
+
* @virtual
|
|
766
|
+
*/
|
|
560
767
|
vfunc_click_behavior(): ClickBehavior;
|
|
768
|
+
/**
|
|
769
|
+
* @virtual
|
|
770
|
+
*/
|
|
561
771
|
vfunc_closed(): void;
|
|
562
772
|
/**
|
|
563
773
|
* Note: Makes sever dbus calls the first time this is called on a view. Dbus messaging is reduced afterwards.
|
|
774
|
+
* @virtual
|
|
564
775
|
*/
|
|
565
776
|
vfunc_get_children(): View[];
|
|
566
777
|
/**
|
|
567
778
|
* Gets the icon of a view. This icon is used to visually represent the view.
|
|
779
|
+
* @virtual
|
|
568
780
|
*/
|
|
569
781
|
vfunc_get_icon(): string;
|
|
570
782
|
/**
|
|
571
783
|
* Gets the name of a view. This name is a short name best used to represent the view with text.
|
|
784
|
+
* @virtual
|
|
572
785
|
*/
|
|
573
786
|
vfunc_get_name(): string;
|
|
787
|
+
/**
|
|
788
|
+
* @param icon
|
|
789
|
+
* @virtual
|
|
790
|
+
*/
|
|
574
791
|
vfunc_icon_changed(icon: string): void;
|
|
575
792
|
/**
|
|
576
793
|
* Determines if the view is currently active and focused by the user. Useful for an active window indicator.
|
|
794
|
+
* @virtual
|
|
577
795
|
*/
|
|
578
796
|
vfunc_is_active(): boolean;
|
|
579
797
|
/**
|
|
580
798
|
* Determines if the view is currently running. Useful for a running window indicator.
|
|
799
|
+
* @virtual
|
|
581
800
|
*/
|
|
582
801
|
vfunc_is_running(): boolean;
|
|
583
802
|
/**
|
|
584
803
|
* Determines if the view is currently starting. Useful for the startup animation.
|
|
804
|
+
* @virtual
|
|
585
805
|
*/
|
|
586
806
|
vfunc_is_starting(): boolean;
|
|
587
807
|
/**
|
|
588
808
|
* Determines if the view is currently requiring attention. Useful for a running window indicator.
|
|
809
|
+
* @virtual
|
|
589
810
|
*/
|
|
590
811
|
vfunc_is_urgent(): boolean;
|
|
812
|
+
/**
|
|
813
|
+
* @virtual
|
|
814
|
+
*/
|
|
591
815
|
vfunc_is_user_visible(): boolean;
|
|
816
|
+
/**
|
|
817
|
+
* @param old_name
|
|
818
|
+
* @param new_name
|
|
819
|
+
* @virtual
|
|
820
|
+
*/
|
|
592
821
|
vfunc_name_changed(old_name: string, new_name: string): void;
|
|
822
|
+
/**
|
|
823
|
+
* @param running
|
|
824
|
+
* @virtual
|
|
825
|
+
*/
|
|
593
826
|
vfunc_running_changed(running: boolean): void;
|
|
827
|
+
/**
|
|
828
|
+
* @param path
|
|
829
|
+
* @virtual
|
|
830
|
+
*/
|
|
594
831
|
vfunc_set_path(path: string): void;
|
|
832
|
+
/**
|
|
833
|
+
* @param value
|
|
834
|
+
* @virtual
|
|
835
|
+
*/
|
|
595
836
|
vfunc_set_sticky(value: boolean): void;
|
|
837
|
+
/**
|
|
838
|
+
* @param starting
|
|
839
|
+
* @virtual
|
|
840
|
+
*/
|
|
596
841
|
vfunc_starting_changed(starting: boolean): void;
|
|
842
|
+
/**
|
|
843
|
+
* @param urgent
|
|
844
|
+
* @virtual
|
|
845
|
+
*/
|
|
597
846
|
vfunc_urgent_changed(urgent: boolean): void;
|
|
847
|
+
/**
|
|
848
|
+
* @param user_visible
|
|
849
|
+
* @virtual
|
|
850
|
+
*/
|
|
598
851
|
vfunc_user_visible_changed(user_visible: boolean): void;
|
|
599
852
|
/**
|
|
600
853
|
* The view type of a window is a short string used to represent all views of the same class. These
|
|
601
854
|
* descriptions should not be used to do casting as they are not considered stable.
|
|
855
|
+
* @virtual
|
|
602
856
|
*/
|
|
603
857
|
vfunc_view_type(): string;
|
|
604
858
|
|
|
@@ -606,7 +860,7 @@ export namespace Bamf {
|
|
|
606
860
|
|
|
607
861
|
/**
|
|
608
862
|
* Note: Makes sever dbus calls the first time this is called on a view. Dbus messaging is reduced afterwards.
|
|
609
|
-
* @returns Returns a list of
|
|
863
|
+
* @returns Returns a list of {@link Bamf.View} which must be freed after usage. Elements of the list are owned by bamf and should not be unreffed.
|
|
610
864
|
*/
|
|
611
865
|
get_children(): View[];
|
|
612
866
|
get_click_suggestion(): ClickBehavior;
|
|
@@ -623,6 +877,10 @@ export namespace Bamf {
|
|
|
623
877
|
* descriptions should not be used to do casting as they are not considered stable.
|
|
624
878
|
*/
|
|
625
879
|
get_view_type(): string;
|
|
880
|
+
/**
|
|
881
|
+
* @param child
|
|
882
|
+
* @returns `true` whether the {@link Bamf.View} `view` has the specified `child`.
|
|
883
|
+
*/
|
|
626
884
|
has_child(child: View): boolean;
|
|
627
885
|
/**
|
|
628
886
|
* Determines if the view is currently active and focused by the user. Useful for an active window indicator.
|
|
@@ -645,20 +903,34 @@ export namespace Bamf {
|
|
|
645
903
|
* Determines if the view is currently requiring attention. Useful for a running window indicator.
|
|
646
904
|
*/
|
|
647
905
|
is_urgent(): boolean;
|
|
906
|
+
/**
|
|
907
|
+
* @returns a boolean useful for determining if a particular view is "user visible". User visible is a concept relating to whether or not a window should be shown in a launcher tasklist.
|
|
908
|
+
*/
|
|
648
909
|
is_user_visible(): boolean;
|
|
649
910
|
/**
|
|
650
911
|
* Note: Makes sever dbus calls the first time this is called on a view.
|
|
651
912
|
* Dbus messaging is reduced afterwards.
|
|
652
|
-
* @returns Returns a list of
|
|
913
|
+
* @returns Returns a list of {@link Bamf.View} which is owned by the {@link Bamf.View} and should not freed or modified after usage.
|
|
653
914
|
*/
|
|
654
915
|
peek_children(): View[];
|
|
916
|
+
/**
|
|
917
|
+
* @param value
|
|
918
|
+
*/
|
|
655
919
|
set_sticky(value: boolean): void;
|
|
656
920
|
}
|
|
657
921
|
|
|
658
922
|
namespace Window {
|
|
659
923
|
// Signal signatures
|
|
660
924
|
interface SignalSignatures extends View.SignalSignatures {
|
|
925
|
+
/**
|
|
926
|
+
* @signal
|
|
927
|
+
* @run-first
|
|
928
|
+
*/
|
|
661
929
|
'maximized-changed': (arg0: number, arg1: number) => void;
|
|
930
|
+
/**
|
|
931
|
+
* @signal
|
|
932
|
+
* @run-first
|
|
933
|
+
*/
|
|
662
934
|
'monitor-changed': (arg0: number, arg1: number) => void;
|
|
663
935
|
'notify::active': (pspec: GObject.ParamSpec) => void;
|
|
664
936
|
'notify::path': (pspec: GObject.ParamSpec) => void;
|
|
@@ -673,6 +945,9 @@ export namespace Bamf {
|
|
|
673
945
|
interface ConstructorProps extends View.ConstructorProps {}
|
|
674
946
|
}
|
|
675
947
|
|
|
948
|
+
/**
|
|
949
|
+
* @gir-type Class
|
|
950
|
+
*/
|
|
676
951
|
class Window extends View {
|
|
677
952
|
static $gtype: GObject.GType<Window>;
|
|
678
953
|
|
|
@@ -693,16 +968,19 @@ export namespace Bamf {
|
|
|
693
968
|
|
|
694
969
|
// Signals
|
|
695
970
|
|
|
971
|
+
/** @signal */
|
|
696
972
|
connect<K extends keyof Window.SignalSignatures>(
|
|
697
973
|
signal: K,
|
|
698
974
|
callback: GObject.SignalCallback<this, Window.SignalSignatures[K]>,
|
|
699
975
|
): number;
|
|
700
976
|
connect(signal: string, callback: (...args: any[]) => any): number;
|
|
977
|
+
/** @signal */
|
|
701
978
|
connect_after<K extends keyof Window.SignalSignatures>(
|
|
702
979
|
signal: K,
|
|
703
980
|
callback: GObject.SignalCallback<this, Window.SignalSignatures[K]>,
|
|
704
981
|
): number;
|
|
705
982
|
connect_after(signal: string, callback: (...args: any[]) => any): number;
|
|
983
|
+
/** @signal */
|
|
706
984
|
emit<K extends keyof Window.SignalSignatures>(
|
|
707
985
|
signal: K,
|
|
708
986
|
...args: GObject.GjsParameters<Window.SignalSignatures[K]> extends [any, ...infer Q] ? Q : never
|
|
@@ -711,22 +989,63 @@ export namespace Bamf {
|
|
|
711
989
|
|
|
712
990
|
// Virtual methods
|
|
713
991
|
|
|
992
|
+
/**
|
|
993
|
+
* @virtual
|
|
994
|
+
*/
|
|
714
995
|
vfunc_get_monitor(): number;
|
|
996
|
+
/**
|
|
997
|
+
* @virtual
|
|
998
|
+
*/
|
|
715
999
|
vfunc_get_pid(): number;
|
|
716
|
-
|
|
1000
|
+
/**
|
|
1001
|
+
* @virtual
|
|
1002
|
+
*/
|
|
1003
|
+
vfunc_get_transient(): Window | null;
|
|
1004
|
+
/**
|
|
1005
|
+
* @param prop
|
|
1006
|
+
* @virtual
|
|
1007
|
+
*/
|
|
717
1008
|
vfunc_get_utf8_prop(prop: string): string;
|
|
1009
|
+
/**
|
|
1010
|
+
* @virtual
|
|
1011
|
+
*/
|
|
718
1012
|
vfunc_get_window_type(): WindowType;
|
|
1013
|
+
/**
|
|
1014
|
+
* @virtual
|
|
1015
|
+
*/
|
|
719
1016
|
vfunc_get_xid(): number;
|
|
1017
|
+
/**
|
|
1018
|
+
* @virtual
|
|
1019
|
+
*/
|
|
720
1020
|
vfunc_last_active(): number;
|
|
1021
|
+
/**
|
|
1022
|
+
* @virtual
|
|
1023
|
+
*/
|
|
721
1024
|
vfunc_maximized(): WindowMaximizationType;
|
|
1025
|
+
/**
|
|
1026
|
+
* @param old_value
|
|
1027
|
+
* @param new_value
|
|
1028
|
+
* @virtual
|
|
1029
|
+
*/
|
|
722
1030
|
vfunc_maximized_changed(old_value: number, new_value: number): void;
|
|
1031
|
+
/**
|
|
1032
|
+
* @param old_value
|
|
1033
|
+
* @param new_value
|
|
1034
|
+
* @virtual
|
|
1035
|
+
*/
|
|
723
1036
|
vfunc_monitor_changed(old_value: number, new_value: number): void;
|
|
724
1037
|
|
|
725
1038
|
// Methods
|
|
726
1039
|
|
|
727
1040
|
get_monitor(): number;
|
|
728
1041
|
get_pid(): number;
|
|
729
|
-
|
|
1042
|
+
/**
|
|
1043
|
+
* @returns A transient for this {@link Bamf.Window}.
|
|
1044
|
+
*/
|
|
1045
|
+
get_transient(): Window | null;
|
|
1046
|
+
/**
|
|
1047
|
+
* @param prop
|
|
1048
|
+
*/
|
|
730
1049
|
get_utf8_prop(prop: string): string;
|
|
731
1050
|
get_window_type(): WindowType;
|
|
732
1051
|
get_xid(): number;
|
|
@@ -734,36 +1053,44 @@ export namespace Bamf {
|
|
|
734
1053
|
maximized(): WindowMaximizationType;
|
|
735
1054
|
}
|
|
736
1055
|
|
|
1056
|
+
/**
|
|
1057
|
+
* @gir-type Alias
|
|
1058
|
+
*/
|
|
737
1059
|
type ApplicationClass = typeof Application;
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
1060
|
+
/**
|
|
1061
|
+
* @gir-type Alias
|
|
1062
|
+
*/
|
|
742
1063
|
type ControlClass = typeof Control;
|
|
1064
|
+
/**
|
|
1065
|
+
* @gir-type Struct
|
|
1066
|
+
*/
|
|
743
1067
|
abstract class ControlPrivate {
|
|
744
1068
|
static $gtype: GObject.GType<ControlPrivate>;
|
|
745
1069
|
}
|
|
746
1070
|
|
|
1071
|
+
/**
|
|
1072
|
+
* @gir-type Alias
|
|
1073
|
+
*/
|
|
747
1074
|
type MatcherClass = typeof Matcher;
|
|
1075
|
+
/**
|
|
1076
|
+
* @gir-type Struct
|
|
1077
|
+
*/
|
|
748
1078
|
abstract class MatcherPrivate {
|
|
749
1079
|
static $gtype: GObject.GType<MatcherPrivate>;
|
|
750
1080
|
}
|
|
751
1081
|
|
|
1082
|
+
/**
|
|
1083
|
+
* @gir-type Alias
|
|
1084
|
+
*/
|
|
752
1085
|
type TabClass = typeof Tab;
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
1086
|
+
/**
|
|
1087
|
+
* @gir-type Alias
|
|
1088
|
+
*/
|
|
757
1089
|
type ViewClass = typeof View;
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
|
|
1090
|
+
/**
|
|
1091
|
+
* @gir-type Alias
|
|
1092
|
+
*/
|
|
762
1093
|
type WindowClass = typeof Window;
|
|
763
|
-
abstract class WindowPrivate {
|
|
764
|
-
static $gtype: GObject.GType<WindowPrivate>;
|
|
765
|
-
}
|
|
766
|
-
|
|
767
1094
|
/**
|
|
768
1095
|
* Name of the imported GIR library
|
|
769
1096
|
* `see` https://gitlab.gnome.org/GNOME/gjs/-/blob/master/gi/ns.cpp#L188
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@girs/bamf-3",
|
|
3
|
-
"version": "3.0.0-4.0.0-beta.
|
|
3
|
+
"version": "3.0.0-4.0.0-beta.41",
|
|
4
4
|
"description": "GJS TypeScript type definitions for Bamf-3, generated from library version 3.0.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"module": "bamf-3.js",
|
|
@@ -31,9 +31,9 @@
|
|
|
31
31
|
"test": "tsc --project tsconfig.json"
|
|
32
32
|
},
|
|
33
33
|
"dependencies": {
|
|
34
|
-
"@girs/gjs": "4.0.0-beta.
|
|
35
|
-
"@girs/gobject-2.0": "2.
|
|
36
|
-
"@girs/glib-2.0": "2.
|
|
34
|
+
"@girs/gjs": "4.0.0-beta.41",
|
|
35
|
+
"@girs/gobject-2.0": "2.88.0-4.0.0-beta.41",
|
|
36
|
+
"@girs/glib-2.0": "2.88.0-4.0.0-beta.41" },
|
|
37
37
|
"devDependencies": {
|
|
38
38
|
"typescript": "*"
|
|
39
39
|
},
|
package/tsconfig.json
CHANGED
|
@@ -17,7 +17,18 @@
|
|
|
17
17
|
"inlineSources": false,
|
|
18
18
|
"newLine": "LF",
|
|
19
19
|
// Show diagnostics
|
|
20
|
-
"diagnostics": true
|
|
20
|
+
"diagnostics": true,
|
|
21
|
+
"paths": {
|
|
22
|
+
"@girs/gobject-2.0": [
|
|
23
|
+
"../gobject-2.0/index.d.ts"
|
|
24
|
+
],
|
|
25
|
+
"@girs/glib-2.0": [
|
|
26
|
+
"../glib-2.0/index.d.ts"
|
|
27
|
+
],
|
|
28
|
+
"@girs/gjs": [
|
|
29
|
+
"../gjs/index.d.ts"
|
|
30
|
+
]
|
|
31
|
+
}
|
|
21
32
|
},
|
|
22
33
|
"include": ["./bamf-3.d.ts"]
|
|
23
34
|
}
|
package/typedoc.json
CHANGED
|
@@ -2,6 +2,8 @@
|
|
|
2
2
|
"entryPoints": ["./bamf-3.d.ts"],
|
|
3
3
|
"readme": "./README.md",
|
|
4
4
|
"name": "Bamf-3",
|
|
5
|
-
"tsconfig": "./tsconfig.json"
|
|
5
|
+
"tsconfig": "./tsconfig.json",
|
|
6
|
+
"skipErrorChecking": true,
|
|
7
|
+
"highlightLanguages": ["typescript", "javascript", "c", "cpp", "xml", "bash", "json", "css"]
|
|
6
8
|
}
|
|
7
9
|
|