home · contact · privacy
Refactored similar array append activities into array_append().
[plomrogue] / src / client / misc.h
index e8497033bcec4a06711caf99655f6022fc47cde6..30f171027bdc76e53acf5a8e26cbc326f8fcf0b2 100644 (file)
@@ -7,7 +7,8 @@
 #ifndef MISC_H
 #define MISC_H
 
-#include <stdint.h> /* for uint16_t */
+#include <stddef.h> /* size_t */
+#include <stdint.h> /* uint32_t */
 
 
 
@@ -15,8 +16,8 @@
 extern void obey_argv(int argc, char * argv[]);
 
 /* Save / load (init) / unload (free/dissolve) / reload interface configuration
- * data, world.wmeta.pad (initialized before opening any windows to the height
- * of the terminal screen and a width of 1) and window chains.
+ * data, world.wins.pad (initialized before opening any windows to the height of
+ * the terminal screen and a width of 1) and window chains.
  *
  * Note that reload_interface_conf() also calls map_center().
  */
@@ -25,20 +26,14 @@ extern void load_interface_conf();
 extern void unload_interface_conf();
 extern void reload_interface_conf();
 
-/* The SIGWINCH handler winch_called() merely sets world.winch to 1. This info
- * is used by io_loop() to call reset_windows(), which adapts the currently
- * loaded interface configuration to the new screen size.
- */
-extern void winch_called();
-extern void reset_windows();
-
-/* Return offset into center map of "mapsize" on "position" in "framesize". */
-extern uint16_t center_offset(uint16_t position,
-                              uint16_t mapsize, uint16_t framesize);
-
 /* Move world.inventory_sel up ("dir"="u") or down (else) as far as possible. */
 extern void nav_inventory(char dir);
 
+/* Append to array pointed to by "ptr_old_array" of "old_n" elements of
+ * "region_size" "new region".
+ */
+extern void array_append(uint32_t old_n, size_t region_size, void * new_region,
+                         void ** ptr_old_array);
 
 
 #endif