mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 06:57:46 +00:00
Kernel+LibC: Rename shared buffer syscalls to use a prefix
This feels a lot more consistent and Unixy: create_shared_buffer() => shbuf_create() share_buffer_with() => shbuf_allow_pid() share_buffer_globally() => shbuf_allow_all() get_shared_buffer() => shbuf_get() release_shared_buffer() => shbuf_release() seal_shared_buffer() => shbuf_seal() get_shared_buffer_size() => shbuf_get_size() Also, "shared_buffer_id" is shortened to "shbuf_id" all around.
This commit is contained in:
parent
8460d02651
commit
f72e5bbb17
36 changed files with 549 additions and 549 deletions
|
@ -103,14 +103,14 @@ void PlaybackManager::remove_dead_buffers()
|
|||
int id = m_connection->get_playing_buffer();
|
||||
int current_id = -1;
|
||||
if (m_current_buffer)
|
||||
current_id = m_current_buffer->shared_buffer_id();
|
||||
current_id = m_current_buffer->shbuf_id();
|
||||
|
||||
if (id >= 0 && id != current_id) {
|
||||
while (!m_buffers.is_empty()) {
|
||||
--m_next_ptr;
|
||||
auto buffer = m_buffers.take_first();
|
||||
|
||||
if (buffer->shared_buffer_id() == id) {
|
||||
if (buffer->shbuf_id() == id) {
|
||||
m_current_buffer = buffer;
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -267,7 +267,7 @@ GUI::Variant ProcessModel::data(const GUI::ModelIndex& index, Role role) const
|
|||
switch (index.column()) {
|
||||
case Column::Icon:
|
||||
if (thread.current_state.icon_id != -1) {
|
||||
auto icon_buffer = SharedBuffer::create_from_shared_buffer_id(thread.current_state.icon_id);
|
||||
auto icon_buffer = SharedBuffer::create_from_shbuf_id(thread.current_state.icon_id);
|
||||
if (icon_buffer) {
|
||||
auto icon_bitmap = Gfx::Bitmap::create_with_shared_buffer(Gfx::BitmapFormat::RGBA32, *icon_buffer, { 16, 16 });
|
||||
if (icon_bitmap)
|
||||
|
|
|
@ -177,7 +177,7 @@ void TaskbarWindow::wm_event(GUI::WMEvent& event)
|
|||
changed_event.icon_buffer_id());
|
||||
#endif
|
||||
if (auto* window = WindowList::the().window(identifier)) {
|
||||
auto buffer = SharedBuffer::create_from_shared_buffer_id(changed_event.icon_buffer_id());
|
||||
auto buffer = SharedBuffer::create_from_shbuf_id(changed_event.icon_buffer_id());
|
||||
ASSERT(buffer);
|
||||
window->button()->set_icon(Gfx::Bitmap::create_with_shared_buffer(Gfx::BitmapFormat::RGBA32, *buffer, changed_event.icon_size()));
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue