feat(windows): fix windows bugs
This commit is contained in:
17
src/main.zig
17
src/main.zig
@@ -20,21 +20,26 @@ pub fn main() !void {
|
||||
var localContentProvider = local_provider.LocalContentProvider{ .threadPool = &pool };
|
||||
|
||||
const fullName: models.FullName = .{ .path = "/home/adam/1.txt" };
|
||||
var item = try localContentProvider.getItemByFullName(fullName, allocator, allocator);
|
||||
var item = try localContentProvider.getItemByFullName(fullName, &.{}, allocator);
|
||||
defer item.deinit();
|
||||
|
||||
const homeFullName: models.FullName = .{ .path = "/home/adam/" };
|
||||
var homeItem = try localContentProvider.getItemByFullName(homeFullName, allocator, allocator);
|
||||
defer homeItem.deinit();
|
||||
const homeFullName: models.FullName = .{ .path = "C:\\Users\\adakovacs" };
|
||||
const homeItem = try localContentProvider.getItemByFullName(homeFullName, &.{}, allocator);
|
||||
// defer homeItem.deinit();
|
||||
const c = switch (homeItem.item) {
|
||||
.container => |c| c,
|
||||
.element => unreachable,
|
||||
};
|
||||
|
||||
var tab1 = Tab.create(&pool, allocator);
|
||||
var tab1 = try allocator.create(Tab);
|
||||
defer allocator.destroy(tab1);
|
||||
|
||||
tab1.init(&pool, allocator);
|
||||
defer tab1.deinit();
|
||||
|
||||
tab1.setCurrentLocation(c);
|
||||
|
||||
std.Thread.sleep(1 * std.time.ns_per_s);
|
||||
std.Thread.sleep(5 * std.time.ns_per_s);
|
||||
}
|
||||
|
||||
const std = @import("std");
|
||||
|
||||
Reference in New Issue
Block a user