Andreas Kling
108b663618
GScrollBar: Clicking in the gutter should jump directly to that position.
...
I think I like how this feels but I'm not 100% sure yet, so I'm leaving
the old feel in behind an #ifdef.
2019-03-25 05:03:40 +01:00
Andreas Kling
614dafea32
FileManager+LibGUI: Show thumbnail generation progress in the statusbar.
2019-03-25 04:25:25 +01:00
Andreas Kling
32191b0d4b
GBoxLayout: Don't subtract margins from the available space twice.
2019-03-25 04:24:20 +01:00
Andreas Kling
17b9fb7bfc
AK: HashMap::set() didn't save new values for existing keys.
2019-03-25 04:23:17 +01:00
Andreas Kling
1c67788933
FileManager: Don't use 32x32 thumbnails for the table view.
2019-03-25 02:16:47 +01:00
Andreas Kling
ab11f42094
Kernel: Do timekeeping manually instead of asking the RTC all the time.
...
This introduces a tiny amount of timer drift which I will have to fix
somehow eventually, but it's a huge improvement in timing consistency
as we no longer suddenly jump from e.g 10:45:49.123 to 10:45:50.000.
2019-03-25 02:06:57 +01:00
Andreas Kling
20f7d7ec67
LibGUI: Add GWidget::doubleclick_event().
...
Now double-clicking an item in a GTableView or GItemView will activate it.
2019-03-25 01:43:32 +01:00
Andreas Kling
43f9027968
FileManager: Add toolbar buttons for switching the view mode.
2019-03-25 01:29:45 +01:00
Andreas Kling
b4da451c9a
WindowServer+LibGUI: Implement automatic cursor tracking.
...
When a mouse button is pressed inside a window, put that window into an
automatic mouse tracking state where all mouse events are sent to that
window until all mouse buttons are released.
This might feel even better if it only cared about the mouse buttons you
actually pressed while *inside* the windows to get released, I don't know.
I'll have to use it for a while and see how it's like.
2019-03-24 15:01:56 +01:00
Andreas Kling
e84823360d
WindowServer: Moving a window to front should always activate it.
...
So instead of having move_to_front() + set_active_window(), let's have
move_to_front_and_make_active().
2019-03-24 13:09:46 +01:00
Andreas Kling
56ee8bfe2a
WindowServer: Factor out ongoing drag/resize from process_mouse_event().
...
The mouse event processing code is getting unwieldy. Break out two huge
chunks into separate functions so the code becomes easier to work with.
2019-03-24 13:00:12 +01:00
Andreas Kling
900a3966e2
FileManager: Don't show "." and ".." in directory views.
2019-03-24 12:27:02 +01:00
Andreas Kling
f18ed4f633
WindowServer: Reduce debug spam.
2019-03-24 04:29:33 +01:00
Andreas Kling
86413a6f5a
LibGUI+FileManager: Add a GIcon class to support multi-size icons.
...
A GIcon can contain any number of bitmaps internally, and will give you
the best fitting icon when you call bitmap_for_size().
2019-03-24 04:28:36 +01:00
Andreas Kling
7e54fdce99
QuickShow: Fill the window with white if the opened image has alpha.
2019-03-24 03:07:00 +01:00
Andreas Kling
812dc1e9ea
FileManager: Add a very naive thumbnail generation thread.
...
This is pretty rickety since we don't have any synchronization primitives.
2019-03-24 03:00:08 +01:00
Andreas Kling
e7c1caa2b5
Kernel: Don't hang the system on unrecoverable page fault.
...
I needed this while debugging threads and now they basically work pretty
well so we can remove this. :^)
2019-03-24 02:11:07 +01:00
Andreas Kling
239c0bd6a6
Kernel: Make block() and yield() automatically call Scheduler::yield().
...
This exposed some places we were accidentally doing a double yield().
2019-03-24 01:52:10 +01:00
Andreas Kling
5713c3a0cb
Kernel: Fix broken destruction order for Process/Thread.
2019-03-24 01:20:35 +01:00
Andreas Kling
b6cd66c3b5
AK: Uh, okay, it seems like we need those 64-bit division helpers after all.
2019-03-24 01:19:51 +01:00
Andreas Kling
db6084538f
AK: Don't compile the 64-bit division helpers in userland builds.
2019-03-24 00:53:56 +01:00
Andreas Kling
31871557e4
LibC: Add ftruncate() stub.
2019-03-24 00:53:39 +01:00
Andreas Kling
eabc097dd4
SharedGraphics: Oops, I was compiling puff() in SLOW mode for testing.
2019-03-24 00:53:16 +01:00
Andreas Kling
fa7f532c35
Kernel: Add a Thread::all_threads() helper.
2019-03-23 23:50:49 +01:00
Andreas Kling
e561ab1b0b
Kernel+LibC: Add a simple create_thread() syscall.
...
It takes two parameters, a function pointer for the entry function,
and a void* argument to be passed to that function on the new thread.
2019-03-23 22:59:08 +01:00
Andreas Kling
7f1757b16c
IRCClient: Exit the main loop when closing the app window.
2019-03-23 22:58:53 +01:00
Andreas Kling
6416123cfb
Kernel: Set the colonel task to low priority.
...
This gives it a smaller time slice, improving responsiveness.
2019-03-23 22:22:01 +01:00
Andreas Kling
8501fdc6f5
Kernel: Don't add the colonel process' main thread to g_threads.
...
This was causing the colonel to get scheduled when he wasn't needed.
2019-03-23 22:17:38 +01:00
Andreas Kling
60d25f0f4a
Kernel: Introduce threads, and refactor everything in support of it.
...
The scheduler now operates on threads, rather than on processes.
Each process has a main thread, and can have any number of additional
threads. The process exits when the main thread exits.
This patch doesn't actually spawn any additional threads, it merely
does all the plumbing needed to make it possible. :^)
2019-03-23 22:03:17 +01:00
Andreas Kling
b0de6aa8d8
Base: Import some 32x32 icons.
2019-03-23 12:38:41 +01:00
Andreas Kling
92627154a7
FileManager: Add basic thumbnailing of PNG images.
...
These use nearest neighbor and are computed synchronously on directory load
so it's neither fast nor very beautiful. These issues both need work on
other parts of the system to fix.
2019-03-23 12:37:33 +01:00
Andreas Kling
1355d09c72
GItemView: Implement up/down/left/right keyboard navigation.
2019-03-23 04:05:58 +01:00
Andreas Kling
82ca3e58b8
FileManager: Make sure the status bar callback is hooked up.
2019-03-23 03:56:33 +01:00
Andreas Kling
19fa70c821
LibGUI: Add a GItemView class.
...
This is a GAbstractView subclass that implements a icon-based view onto
a GModel. It still need a bunch of work, but it's in basic usable shape.
2019-03-23 03:54:45 +01:00
Andreas Kling
5707d7f547
LibGUI: Add GAbstractView base class for GTableView.
...
This is in preparation for adding a new view class.
2019-03-23 02:04:31 +01:00
Andreas Kling
994cf10b3e
LibGUI: Rename GTableModel => GModel.
2019-03-23 01:42:49 +01:00
Andreas Kling
9d4b4c2689
FileManager: Add a default icon for image files.
2019-03-22 12:54:27 +01:00
Andreas Kling
5ca62f356b
FileManager: Open PNG files with QuickShow when activated.
2019-03-22 12:43:29 +01:00
Andreas Kling
d563dc0565
LibGUI: Add a setting to make GLabel stretch its icon.
...
Use this in QuickShow to allow arbitrarily scaling the opened image.
2019-03-22 04:20:48 +01:00
Andreas Kling
86570d3b1a
SharedGraphics: Add Painter::draw_scaled_bitmap().
...
It's just a simple nearest-neighbor scale with alpha blending but it gets
the job done.
2019-03-22 04:20:10 +01:00
Andreas Kling
e4498194c2
LibGUI: Remove unnecessary timer in GProgressBar.
2019-03-22 02:49:57 +01:00
Andreas Kling
c3b0c1ba68
LibGUI: Add a GProgressBar widget.
2019-03-22 02:49:45 +01:00
Andreas Kling
23fe630057
AK: Allow printing a literal '%' character with the printf family.
2019-03-22 01:50:32 +01:00
Andreas Kling
7c0a185970
Use the PNG loader for all images, and get rid of the .rgb files.
2019-03-22 00:21:03 +01:00
Andreas Kling
c2a38c86cf
AK: Fix busted __udivmoddi4() implementation.
2019-03-21 17:33:06 +01:00
Andreas Kling
1484a9eabd
WindowServer: Remove some old commented-out code.
2019-03-21 17:22:29 +01:00
Andreas Kling
796bc56a13
PNGLoader: Reduce unfiltering branchiness even more.
...
Use a dummy scanline for y=0 filled with all zeroes to avoid having to check
y on every iteration before grabbing color data from scanline[y - 1].
2019-03-21 16:55:31 +01:00
Andreas Kling
cd1afde48c
PNGLoader: Templatize the unfiltering functions to reduce branchiness.
...
This also allows us to dodge processing alpha values in non-alpha PNGs
without a branch.
2019-03-21 16:45:04 +01:00
Andreas Kling
cfc521d57e
PNGLoader: Reorganize the unfiltering code to make it easier to work with.
2019-03-21 16:19:11 +01:00
Andreas Kling
e4dfd5a3a4
WindowServer: Support PNG wallpapers.
...
Fix up /bin/pape so it tells the WindowServer which wallpaper file to use.
2019-03-21 15:54:19 +01:00