-#define HASHKEY_FORMAT_STRING "%d-%d-%d-%d-%d-%d-%.3f-%.3f"
-#define HASHKEY_FORMAT_STRING_NOSHRINK_NOR_ALPHA "%d-%d-%d-%d-%d-"
+#define HASHKEY_FORMAT_STRING "%d-%d-%d-%d-%d-%d-%d-%.3f-%.3f"
+#define HASHKEY_FORMAT_STRING_NOSHRINK_NOR_ALPHA "%d-%d-%d-%d-%d-%d-"
+#define HASHKEY_FORMAT_STRING_TYPE "%d-"
+
+static VikLayerParamScale params_scales[] = {
+ /* min, max, step, digits (decimal places) */
+ { 1, 1024, 1, 0 },
+};
+
+static VikLayerParam prefs[] = {
+ { VIK_LAYER_NUM_TYPES, VIKING_PREFERENCES_NAMESPACE "mapcache_size", VIK_LAYER_PARAM_UINT, VIK_LAYER_GROUP_NONE, N_("Map cache memory size (MB):"), VIK_LAYER_WIDGET_HSCALE, params_scales, NULL, NULL, NULL, NULL, NULL },
+};
+
+static void cache_item_free (cache_item_t *ci)
+{
+ g_object_unref ( ci->pixbuf );
+ g_free ( ci );
+}