devkit-2012

Abstract

This document is used to note information for os development.

Mechanism

  • Event Loop

source: http://en.wikipedia.org/wiki/Event_loop

main():

file_fd = open ("logfile") x_fd = open_display () construct_interface () while changed_fds = select ({file_fd, x_fd}): if file_fd in changed_fds: data = read_from (file_fd) append_to_display (data) send_repaint_message () if x_fd in changed_fds: process_x_messages ()