r11572 jmb - /trunk/libcss/src/select/select.c
by netsurf@semichrome.net
Author: jmb
Date: Mon Jan 31 17:44:53 2011
New Revision: 11572
URL: http://source.netsurf-browser.org?rev=11572&view=rev
Log:
The document root element cannot be the child of anything
Modified:
trunk/libcss/src/select/select.c
Modified: trunk/libcss/src/select/select.c
URL: http://source.netsurf-browser.org/trunk/libcss/src/select/select.c?rev=11...
==============================================================================
--- trunk/libcss/src/select/select.c (original)
+++ trunk/libcss/src/select/select.c Mon Jan 31 17:44:53 2011
@@ -1351,6 +1351,7 @@
const css_selector_detail *detail, css_select_state *state,
bool *match, css_pseudo_element *pseudo_element)
{
+ bool is_root = false;
css_error error = CSS_OK;
UNUSED(ctx);
@@ -1374,14 +1375,19 @@
detail->name, match);
break;
case CSS_SELECTOR_PSEUDO_CLASS:
- if (detail->name == state->first_child) {
+ error = state->handler->node_is_root(state->pw, node, &is_root);
+ if (error != CSS_OK)
+ return error;
+
+ if (is_root == false && detail->name == state->first_child) {
int32_t num_before = 0;
error = state->handler->node_count_siblings(state->pw,
node, false, false, &num_before);
if (error == CSS_OK)
*match = (num_before == 0);
- } else if (detail->name == state->nth_child) {
+ } else if (is_root == false &&
+ detail->name == state->nth_child) {
int32_t num_before = 0;
error = state->handler->node_count_siblings(state->pw,
@@ -1392,7 +1398,8 @@
*match = match_nth(a, b, num_before + 1);
}
- } else if (detail->name == state->nth_last_child) {
+ } else if (is_root == false &&
+ detail->name == state->nth_last_child) {
int32_t num_after = 0;
error = state->handler->node_count_siblings(state->pw,
@@ -1403,7 +1410,8 @@
*match = match_nth(a, b, num_after + 1);
}
- } else if (detail->name == state->nth_of_type) {
+ } else if (is_root == false &&
+ detail->name == state->nth_of_type) {
int32_t num_before = 0;
error = state->handler->node_count_siblings(state->pw,
@@ -1414,7 +1422,8 @@
*match = match_nth(a, b, num_before + 1);
}
- } else if (detail->name == state->nth_last_of_type) {
+ } else if (is_root == false &&
+ detail->name == state->nth_last_of_type) {
int32_t num_after = 0;
error = state->handler->node_count_siblings(state->pw,
@@ -1425,28 +1434,32 @@
*match = match_nth(a, b, num_after + 1);
}
- } else if (detail->name == state->last_child) {
+ } else if (is_root == false &&
+ detail->name == state->last_child) {
int32_t num_after = 0;
error = state->handler->node_count_siblings(state->pw,
node, false, true, &num_after);
if (error == CSS_OK)
*match = (num_after == 0);
- } else if (detail->name == state->first_of_type) {
+ } else if (is_root == false &&
+ detail->name == state->first_of_type) {
int32_t num_before = 0;
error = state->handler->node_count_siblings(state->pw,
node, true, false, &num_before);
if (error == CSS_OK)
*match = (num_before == 0);
- } else if (detail->name == state->last_of_type) {
+ } else if (is_root == false &&
+ detail->name == state->last_of_type) {
int32_t num_after = 0;
error = state->handler->node_count_siblings(state->pw,
node, true, true, &num_after);
if (error == CSS_OK)
*match = (num_after == 0);
- } else if (detail->name == state->only_child) {
+ } else if (is_root == false &&
+ detail->name == state->only_child) {
int32_t num_before = 0, num_after = 0;
error = state->handler->node_count_siblings(state->pw,
@@ -1459,7 +1472,8 @@
*match = (num_before == 0) &&
(num_after == 0);
}
- } else if (detail->name == state->only_of_type) {
+ } else if (is_root == false &&
+ detail->name == state->only_of_type) {
int32_t num_before = 0, num_after = 0;
error = state->handler->node_count_siblings(state->pw,
@@ -1473,8 +1487,7 @@
(num_after == 0);
}
} else if (detail->name == state->root) {
- error = state->handler->node_is_root(state->pw,
- node, match);
+ *match = is_root;
} else if (detail->name == state->empty) {
error = state->handler->node_is_empty(state->pw,
node, match);
12 years, 7 months
r11570 jmb - /trunk/netsurf/css/select.c
by netsurf@semichrome.net
Author: jmb
Date: Mon Jan 31 16:31:47 2011
New Revision: 11570
URL: http://source.netsurf-browser.org?rev=11570&view=rev
Log:
Various fixes for selection callbacks
Modified:
trunk/netsurf/css/select.c
Modified: trunk/netsurf/css/select.c
URL: http://source.netsurf-browser.org/trunk/netsurf/css/select.c?rev=11570&r1...
==============================================================================
--- trunk/netsurf/css/select.c (original)
+++ trunk/netsurf/css/select.c Mon Jan 31 16:31:47 2011
@@ -658,13 +658,13 @@
*ancestor = NULL;
- for (n = n->parent; n != NULL && n->type == XML_ELEMENT_NODE;
- n = n->parent) {
- bool match = strlen((const char *) n->name) == len &&
+ for (n = n->parent; n != NULL; n = n->parent) {
+ if (n->type != XML_ELEMENT_NODE)
+ continue;
+
+ if (strlen((const char *) n->name) == len &&
strncasecmp((const char *) n->name,
- data, len) == 0;
-
- if (match) {
+ data, len) == 0) {
*ancestor = (void *) n;
break;
}
@@ -693,11 +693,16 @@
*parent = NULL;
- if (n->parent != NULL && n->parent->type == XML_ELEMENT_NODE &&
- strlen((const char *) n->parent->name) == len &&
- strncasecmp((const char *) n->parent->name,
+ /* Find parent element */
+ for (n = n->parent; n != NULL; n = n->parent) {
+ if (n->type == XML_ELEMENT_NODE)
+ break;
+ }
+
+ if (n != NULL && strlen((const char *) n->name) == len &&
+ strncasecmp((const char *) n->name,
data, len) == 0)
- *parent = (void *) n->parent;
+ *parent = (void *) n;
return CSS_OK;
}
@@ -722,13 +727,16 @@
*sibling = NULL;
- while (n->prev != NULL && n->prev->type != XML_ELEMENT_NODE)
- n = n->prev;
-
- if (n->prev != NULL && strlen((const char *) n->prev->name) == len &&
- strncasecmp((const char *) n->prev->name,
+ /* Find sibling element */
+ for (n = n->prev; n != NULL; n = n->prev) {
+ if (n->type == XML_ELEMENT_NODE)
+ break;
+ }
+
+ if (n != NULL && strlen((const char *) n->name) == len &&
+ strncasecmp((const char *) n->name,
data, len) == 0)
- *sibling = (void *) n->prev;
+ *sibling = (void *) n;
return CSS_OK;
}
@@ -753,13 +761,13 @@
*sibling = NULL;
- for (n = n->prev; n != NULL && n->type == XML_ELEMENT_NODE;
- n = n->prev) {
- bool match = strlen((const char *) n->name) == len &&
+ for (n = n->prev; n != NULL; n = n->prev) {
+ if (n->type != XML_ELEMENT_NODE)
+ continue;
+
+ if (strlen((const char *) n->name) == len &&
strncasecmp((const char *) n->name,
- data, len) == 0;
-
- if (match) {
+ data, len) == 0) {
*sibling = (void *) n;
break;
}
@@ -782,10 +790,13 @@
{
xmlNode *n = node;
- if (n->parent != NULL && n->parent->type == XML_ELEMENT_NODE)
- *parent = (void *) n->parent;
- else
- *parent = NULL;
+ /* Find parent element */
+ for (n = n->parent; n != NULL; n = n->parent) {
+ if (n->type == XML_ELEMENT_NODE)
+ break;
+ }
+
+ *parent = (void *) n;
return CSS_OK;
}
@@ -804,10 +815,13 @@
{
xmlNode *n = node;
- while (n->prev != NULL && n->prev->type != XML_ELEMENT_NODE)
- n = n->prev;
-
- *sibling = (void *) n->prev;
+ /* Find sibling element */
+ for (n = n->prev; n != NULL; n = n->prev) {
+ if (n->type == XML_ELEMENT_NODE)
+ break;
+ }
+
+ *sibling = (void *) n;
return CSS_OK;
}
@@ -1018,17 +1032,20 @@
{
xmlNode *n = node;
xmlChar *attr;
+ size_t vlen = lwc_string_length(value);
*match = false;
- attr = xmlGetProp(n, (const xmlChar *) lwc_string_data(name));
- if (attr != NULL) {
- *match = strlen((const char *) attr) ==
- lwc_string_length(value) &&
- strncasecmp((const char *) attr,
- lwc_string_data(value),
- lwc_string_length(value)) == 0;
- xmlFree(attr);
+ if (vlen != 0) {
+ attr = xmlGetProp(n, (const xmlChar *) lwc_string_data(name));
+ if (attr != NULL) {
+ *match = strlen((const char *) attr) ==
+ lwc_string_length(value) &&
+ strncasecmp((const char *) attr,
+ lwc_string_data(value),
+ lwc_string_length(value)) == 0;
+ xmlFree(attr);
+ }
}
return CSS_OK;
@@ -1054,31 +1071,25 @@
{
xmlNode *n = node;
xmlChar *attr;
- size_t vlen = lwc_string_length(value);
+ size_t vlen = lwc_string_length(value);
*match = false;
- attr = xmlGetProp(n, (const xmlChar *) lwc_string_data(name));
- if (attr != NULL) {
- const char *p;
- const char *start = (const char *) attr;
- const char *end = start + strlen(start);
-
- for (p = start; p <= end; p++) {
- if (*p == '-' || *p == '\0') {
- if ((size_t) (p - start) == vlen &&
- strncasecmp(start,
- lwc_string_data(value),
- vlen) == 0) {
- *match = true;
- break;
- }
-
- start = p + 1;
- }
- }
-
- xmlFree(attr);
+ if (vlen != 0) {
+ attr = xmlGetProp(n, (const xmlChar *) lwc_string_data(name));
+ if (attr != NULL) {
+ const char *vdata = lwc_string_data(value);
+ const char *data = (const char *) attr;
+ size_t len = strlen(data);
+
+ if (len == vlen && strcasecmp(data, vdata) == 0)
+ *match = true;
+ else if (len > vlen && data[vlen] == '-' &&
+ strncasecmp(data, vdata, vlen) == 0)
+ *match = true;
+
+ xmlFree(attr);
+ }
}
return CSS_OK;
@@ -1108,27 +1119,29 @@
*match = false;
- attr = xmlGetProp(n, (const xmlChar *) lwc_string_data(name));
- if (attr != NULL) {
- const char *p;
- const char *start = (const char *) attr;
- const char *end = start + strlen(start);
-
- for (p = start; p <= end; p++) {
- if (*p == ' ' || *p == '\0') {
- if ((size_t) (p - start) == vlen &&
- strncasecmp(start,
+ if (vlen != 0) {
+ attr = xmlGetProp(n, (const xmlChar *) lwc_string_data(name));
+ if (attr != NULL) {
+ const char *p;
+ const char *start = (const char *) attr;
+ const char *end = start + strlen(start);
+
+ for (p = start; p <= end; p++) {
+ if (*p == ' ' || *p == '\0') {
+ if ((size_t) (p - start) == vlen &&
+ strncasecmp(start,
lwc_string_data(value),
vlen) == 0) {
- *match = true;
- break;
+ *match = true;
+ break;
+ }
+
+ start = p + 1;
}
-
- start = p + 1;
}
- }
-
- xmlFree(attr);
+
+ xmlFree(attr);
+ }
}
return CSS_OK;
@@ -1158,13 +1171,16 @@
*match = false;
- attr = xmlGetProp(n, (const xmlChar *) lwc_string_data(name));
- if (attr != NULL) {
- if (strlen((char *) attr) >= vlen && strncasecmp((char *) attr,
- lwc_string_data(value), vlen) == 0)
- *match = true;
-
- xmlFree(attr);
+ if (vlen != 0) {
+ attr = xmlGetProp(n, (const xmlChar *) lwc_string_data(name));
+ if (attr != NULL) {
+ if (strlen((char *) attr) >= vlen &&
+ strncasecmp((char *) attr,
+ lwc_string_data(value), vlen) == 0)
+ *match = true;
+
+ xmlFree(attr);
+ }
}
return CSS_OK;
@@ -1194,16 +1210,18 @@
*match = false;
- attr = xmlGetProp(n, (const xmlChar *) lwc_string_data(name));
- if (attr != NULL) {
- size_t len = strlen((char *) attr);
- const char *start = (char *) attr + len - vlen;
-
- if (len >= vlen && strncasecmp(start,
- lwc_string_data(value), vlen) == 0)
- *match = true;
-
- xmlFree(attr);
+ if (vlen != 0) {
+ attr = xmlGetProp(n, (const xmlChar *) lwc_string_data(name));
+ if (attr != NULL) {
+ size_t len = strlen((char *) attr);
+ const char *start = (char *) attr + len - vlen;
+
+ if (len >= vlen && strncasecmp(start,
+ lwc_string_data(value), vlen) == 0)
+ *match = true;
+
+ xmlFree(attr);
+ }
}
return CSS_OK;
@@ -1233,25 +1251,28 @@
*match = false;
- attr = xmlGetProp(n, (const xmlChar *) lwc_string_data(name));
- if (attr != NULL) {
- const char *vdata = lwc_string_data(value);
- size_t len = strlen((char *) attr);
- const char *start = (char *) attr;
- const char *last_start = start + len - vlen;
-
- if (len >= vlen) {
- while (start <= last_start) {
- if (strncasecmp(start, vdata, vlen) == 0) {
- *match = true;
- break;
+ if (vlen != 0) {
+ attr = xmlGetProp(n, (const xmlChar *) lwc_string_data(name));
+ if (attr != NULL) {
+ const char *vdata = lwc_string_data(value);
+ size_t len = strlen((char *) attr);
+ const char *start = (char *) attr;
+ const char *last_start = start + len - vlen;
+
+ if (len >= vlen) {
+ while (start <= last_start) {
+ if (strncasecmp(start, vdata,
+ vlen) == 0) {
+ *match = true;
+ break;
+ }
+
+ start++;
}
-
- start++;
}
- }
-
- xmlFree(attr);
+
+ xmlFree(attr);
+ }
}
return CSS_OK;
@@ -1271,7 +1292,7 @@
{
xmlNode *n = node;
- *match = (n->parent != NULL);
+ *match = (n->parent == NULL);
return CSS_OK;
}
@@ -1298,7 +1319,7 @@
do {
n = after ? n->next : n->prev;
- if (n != NULL && n->type != XML_ELEMENT_NODE) {
+ if (n != NULL && n->type == XML_ELEMENT_NODE) {
if (same_name) {
if (strcasecmp(name, (char *) n->name) == 0)
cnt++;
@@ -1327,9 +1348,15 @@
{
xmlNode *n = node;
- /** \todo This may not be sufficient: all children may be
- * non-content, or empty content nodes. */
- *match = (n->children == NULL);
+ *match = true;
+
+ for (n = n->children; n != NULL; n = n->next) {
+ if (n->type == XML_ELEMENT_NODE ||
+ n->type == XML_TEXT_NODE) {
+ *match = false;
+ break;
+ }
+ }
return CSS_OK;
}
12 years, 7 months
r11569 jmb - in /trunk/libcss/src: select/select.c stylesheet.c
by netsurf@semichrome.net
Author: jmb
Date: Mon Jan 31 16:30:51 2011
New Revision: 11569
URL: http://source.netsurf-browser.org?rev=11569&view=rev
Log:
Fix specificity calculation for prefix, suffix, and substring attribute selectors.
Fix dumping of these selectors when debugging selector chains
Modified:
trunk/libcss/src/select/select.c
trunk/libcss/src/stylesheet.c
Modified: trunk/libcss/src/select/select.c
URL: http://source.netsurf-browser.org/trunk/libcss/src/select/select.c?rev=11...
==============================================================================
--- trunk/libcss/src/select/select.c (original)
+++ trunk/libcss/src/select/select.c Mon Jan 31 16:30:51 2011
@@ -1769,6 +1769,27 @@
(int) lwc_string_length(detail->value),
lwc_string_data(detail->value));
break;
+ case CSS_SELECTOR_ATTRIBUTE_PREFIX:
+ fprintf(stderr, "[%.*s^=\"%.*s\"]",
+ (int) lwc_string_length(detail->name),
+ lwc_string_data(detail->name),
+ (int) lwc_string_length(detail->value),
+ lwc_string_data(detail->value));
+ break;
+ case CSS_SELECTOR_ATTRIBUTE_SUFFIX:
+ fprintf(stderr, "[%.*s$=\"%.*s\"]",
+ (int) lwc_string_length(detail->name),
+ lwc_string_data(detail->name),
+ (int) lwc_string_length(detail->value),
+ lwc_string_data(detail->value));
+ break;
+ case CSS_SELECTOR_ATTRIBUTE_SUBSTRING:
+ fprintf(stderr, "[%.*s*=\"%.*s\"]",
+ (int) lwc_string_length(detail->name),
+ lwc_string_data(detail->name),
+ (int) lwc_string_length(detail->value),
+ lwc_string_data(detail->value));
+ break;
}
if (detail->next)
Modified: trunk/libcss/src/stylesheet.c
URL: http://source.netsurf-browser.org/trunk/libcss/src/stylesheet.c?rev=11569...
==============================================================================
--- trunk/libcss/src/stylesheet.c (original)
+++ trunk/libcss/src/stylesheet.c Mon Jan 31 16:30:51 2011
@@ -971,6 +971,9 @@
case CSS_SELECTOR_ATTRIBUTE_EQUAL:
case CSS_SELECTOR_ATTRIBUTE_DASHMATCH:
case CSS_SELECTOR_ATTRIBUTE_INCLUDES:
+ case CSS_SELECTOR_ATTRIBUTE_PREFIX:
+ case CSS_SELECTOR_ATTRIBUTE_SUFFIX:
+ case CSS_SELECTOR_ATTRIBUTE_SUBSTRING:
(*parent)->specificity += CSS_SPECIFICITY_C;
break;
case CSS_SELECTOR_ID:
12 years, 7 months
r11568 jmb - /trunk/libcss/src/select/hash.c
by netsurf@semichrome.net
Author: jmb
Date: Mon Jan 31 16:30:02 2011
New Revision: 11568
URL: http://source.netsurf-browser.org?rev=11568&view=rev
Log:
Place negated class and id selectors in the universal hash chain
Modified:
trunk/libcss/src/select/hash.c
Modified: trunk/libcss/src/select/hash.c
URL: http://source.netsurf-browser.org/trunk/libcss/src/select/hash.c?rev=1156...
==============================================================================
--- trunk/libcss/src/select/hash.c (original)
+++ trunk/libcss/src/select/hash.c Mon Jan 31 16:30:02 2011
@@ -536,7 +536,8 @@
lwc_string *name = NULL;
do {
- if (detail->type == CSS_SELECTOR_CLASS) {
+ /* Ignore :not(.class) */
+ if (detail->type == CSS_SELECTOR_CLASS && detail->negate == 0) {
name = detail->name;
break;
}
@@ -562,7 +563,8 @@
lwc_string *name = NULL;
do {
- if (detail->type == CSS_SELECTOR_ID) {
+ /* Ignore :not(#id) */
+ if (detail->type == CSS_SELECTOR_ID && detail->negate == 0) {
name = detail->name;
break;
}
12 years, 7 months
r11567 swdr - /trunk/netsurf/cocoa/
by netsurf@semichrome.net
Author: swdr
Date: Mon Jan 31 13:12:00 2011
New Revision: 11567
URL: http://source.netsurf-browser.org?rev=11567&view=rev
Log:
Reorganized includes.
Modified:
trunk/netsurf/cocoa/BrowserView.h
trunk/netsurf/cocoa/BrowserView.m
trunk/netsurf/cocoa/BrowserViewController.m
trunk/netsurf/cocoa/BrowserWindowController.m
trunk/netsurf/cocoa/DownloadWindowController.m
trunk/netsurf/cocoa/FormSelectMenu.m
trunk/netsurf/cocoa/HistoryView.m
trunk/netsurf/cocoa/Makefile.target
trunk/netsurf/cocoa/NetSurfAppDelegate.m
trunk/netsurf/cocoa/NetsurfApp.m
trunk/netsurf/cocoa/ScrollableView.m
trunk/netsurf/cocoa/TreeView.h
trunk/netsurf/cocoa/TreeView.m
trunk/netsurf/cocoa/URLFieldCell.m
trunk/netsurf/cocoa/bitmap.m
trunk/netsurf/cocoa/font.h
trunk/netsurf/cocoa/font.m
trunk/netsurf/cocoa/gui.m
trunk/netsurf/cocoa/plotter.m
trunk/netsurf/cocoa/schedule.m
trunk/netsurf/cocoa/thumbnail.m
trunk/netsurf/cocoa/url.m
trunk/netsurf/cocoa/utils.m
Modified: trunk/netsurf/cocoa/BrowserView.h
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/BrowserView.h?rev=1...
==============================================================================
--- trunk/netsurf/cocoa/BrowserView.h (original)
+++ trunk/netsurf/cocoa/BrowserView.h Mon Jan 31 13:12:00 2011
@@ -18,7 +18,7 @@
#import <Cocoa/Cocoa.h>
-#import "ScrollableView.h"
+#import "cocoa/ScrollableView.h"
@class HistoryView;
@interface BrowserView : ScrollableView {
Modified: trunk/netsurf/cocoa/BrowserView.m
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/BrowserView.m?rev=1...
==============================================================================
--- trunk/netsurf/cocoa/BrowserView.m (original)
+++ trunk/netsurf/cocoa/BrowserView.m Mon Jan 31 13:12:00 2011
@@ -16,8 +16,10 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-#import "BrowserView.h"
-#import "HistoryView.h"
+#import "cocoa/BrowserView.h"
+#import "cocoa/HistoryView.h"
+#import "cocoa/font.h"
+#import "cocoa/plotter.h"
#import "desktop/browser.h"
#import "desktop/history_core.h"
@@ -25,9 +27,6 @@
#import "desktop/textinput.h"
#import "desktop/options.h"
#import "desktop/selection.h"
-
-#import "cocoa/font.h"
-#import "cocoa/plotter.h"
@interface BrowserView ()
Modified: trunk/netsurf/cocoa/BrowserViewController.m
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/BrowserViewControll...
==============================================================================
--- trunk/netsurf/cocoa/BrowserViewController.m (original)
+++ trunk/netsurf/cocoa/BrowserViewController.m Mon Jan 31 13:12:00 2011
@@ -17,9 +17,9 @@
*/
-#import "BrowserViewController.h"
-#import "BrowserView.h"
-#import "BrowserWindowController.h"
+#import "cocoa/BrowserViewController.h"
+#import "cocoa/BrowserView.h"
+#import "cocoa/BrowserWindowController.h"
#import "desktop/browser.h"
#import "desktop/history_core.h"
Modified: trunk/netsurf/cocoa/BrowserWindowController.m
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/BrowserWindowContro...
==============================================================================
--- trunk/netsurf/cocoa/BrowserWindowController.m (original)
+++ trunk/netsurf/cocoa/BrowserWindowController.m Mon Jan 31 13:12:00 2011
@@ -16,12 +16,12 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-#import "BrowserWindowController.h"
-
-#import "BrowserViewController.h"
-#import "PSMTabBarControl.h"
-#import "PSMRolloverButton.h"
-#import "URLFieldCell.h"
+#import "cocoa/BrowserWindowController.h"
+
+#import "cocoa/BrowserViewController.h"
+#import "cocoa/PSMTabBarControl/PSMTabBarControl.h"
+#import "cocoa/PSMTabBarControl/PSMRolloverButton.h"
+#import "cocoa/URLFieldCell.h"
#import "cocoa/gui.h"
#import "cocoa/NetsurfApp.h"
Modified: trunk/netsurf/cocoa/DownloadWindowController.m
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/DownloadWindowContr...
==============================================================================
--- trunk/netsurf/cocoa/DownloadWindowController.m (original)
+++ trunk/netsurf/cocoa/DownloadWindowController.m Mon Jan 31 13:12:00 2011
@@ -16,11 +16,11 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-#import "DownloadWindowController.h"
+#import "cocoa/DownloadWindowController.h"
+#import "cocoa/gui.h"
#import "desktop/download.h"
#import "desktop/gui.h"
-#import "cocoa/gui.h"
@interface DownloadWindowController ()
Modified: trunk/netsurf/cocoa/FormSelectMenu.m
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/FormSelectMenu.m?re...
==============================================================================
--- trunk/netsurf/cocoa/FormSelectMenu.m (original)
+++ trunk/netsurf/cocoa/FormSelectMenu.m Mon Jan 31 13:12:00 2011
@@ -16,10 +16,10 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-#import "FormSelectMenu.h"
+#import "cocoa/FormSelectMenu.h"
+#import "cocoa/coordinates.h"
#import "render/form.h"
-#import "cocoa/coordinates.h"
@interface FormSelectMenu ()
Modified: trunk/netsurf/cocoa/HistoryView.m
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/HistoryView.m?rev=1...
==============================================================================
--- trunk/netsurf/cocoa/HistoryView.m (original)
+++ trunk/netsurf/cocoa/HistoryView.m Mon Jan 31 13:12:00 2011
@@ -16,14 +16,14 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-#import "HistoryView.h"
+#import "cocoa/HistoryView.h"
+#import "cocoa/font.h"
+#import "cocoa/coordinates.h"
+#import "cocoa/plotter.h"
#import "desktop/browser.h"
#import "desktop/history_core.h"
#import "desktop/plotters.h"
-#import "cocoa/font.h"
-#import "cocoa/coordinates.h"
-#import "cocoa/plotter.h"
static NSRect cocoa_history_rect( struct browser_window *bw )
{
Modified: trunk/netsurf/cocoa/Makefile.target
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/Makefile.target?rev...
==============================================================================
--- trunk/netsurf/cocoa/Makefile.target (original)
+++ trunk/netsurf/cocoa/Makefile.target Mon Jan 31 13:12:00 2011
@@ -29,7 +29,6 @@
CFLAGS += -I/usr/X11/include
CFLAGS += -I/usr/include/libxml2
- CFLAGS += -Icocoa/PSMTabBarControl
CFLAGS += -include cocoa/Prefix.pch
ifneq ($(wildcard /opt/local*),)
Modified: trunk/netsurf/cocoa/NetSurfAppDelegate.m
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/NetSurfAppDelegate....
==============================================================================
--- trunk/netsurf/cocoa/NetSurfAppDelegate.m (original)
+++ trunk/netsurf/cocoa/NetSurfAppDelegate.m Mon Jan 31 13:12:00 2011
@@ -16,7 +16,7 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-#import "NetSurfAppDelegate.h"
+#import "cocoa/NetSurfAppDelegate.h"
#import "cocoa/SearchWindowController.h"
#import "cocoa/PreferencesWindowController.h"
Modified: trunk/netsurf/cocoa/NetsurfApp.m
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/NetsurfApp.m?rev=11...
==============================================================================
--- trunk/netsurf/cocoa/NetsurfApp.m (original)
+++ trunk/netsurf/cocoa/NetsurfApp.m Mon Jan 31 13:12:00 2011
@@ -16,29 +16,28 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-#import "NetsurfApp.h"
-
+#import "cocoa/NetsurfApp.h"
#import "cocoa/gui.h"
#import "cocoa/plotter.h"
#import "desktop/gui.h"
-#include "content/urldb.h"
-#include "content/fetch.h"
-#include "css/utils.h"
-#include "desktop/gui.h"
-#include "desktop/history_core.h"
-#include "desktop/mouse.h"
-#include "desktop/netsurf.h"
-#include "desktop/options.h"
-#include "desktop/plotters.h"
-#include "desktop/save_complete.h"
-#include "desktop/selection.h"
-#include "desktop/textinput.h"
-#include "render/html.h"
-#include "utils/url.h"
-#include "utils/log.h"
-#include "utils/messages.h"
-#include "utils/utils.h"
+#import "content/urldb.h"
+#import "content/fetch.h"
+#import "css/utils.h"
+#import "desktop/gui.h"
+#import "desktop/history_core.h"
+#import "desktop/mouse.h"
+#import "desktop/netsurf.h"
+#import "desktop/options.h"
+#import "desktop/plotters.h"
+#import "desktop/save_complete.h"
+#import "desktop/selection.h"
+#import "desktop/textinput.h"
+#import "render/html.h"
+#import "utils/url.h"
+#import "utils/log.h"
+#import "utils/messages.h"
+#import "utils/utils.h"
#import "css/utils.h"
#ifndef NETSURF_HOMEPAGE
Modified: trunk/netsurf/cocoa/ScrollableView.m
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/ScrollableView.m?re...
==============================================================================
--- trunk/netsurf/cocoa/ScrollableView.m (original)
+++ trunk/netsurf/cocoa/ScrollableView.m Mon Jan 31 13:12:00 2011
@@ -16,7 +16,7 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-#import "ScrollableView.h"
+#import "cocoa/ScrollableView.h"
@interface ScrollableView ()
Modified: trunk/netsurf/cocoa/TreeView.h
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/TreeView.h?rev=1156...
==============================================================================
--- trunk/netsurf/cocoa/TreeView.h (original)
+++ trunk/netsurf/cocoa/TreeView.h Mon Jan 31 13:12:00 2011
@@ -18,7 +18,7 @@
#import <Cocoa/Cocoa.h>
-#import "ScrollableView.h"
+#import "cocoa/ScrollableView.h"
@interface TreeView : ScrollableView {
struct tree *treeHandle;
Modified: trunk/netsurf/cocoa/TreeView.m
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/TreeView.m?rev=1156...
==============================================================================
--- trunk/netsurf/cocoa/TreeView.m (original)
+++ trunk/netsurf/cocoa/TreeView.m Mon Jan 31 13:12:00 2011
@@ -16,12 +16,12 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-#import "TreeView.h"
+#import "cocoa/TreeView.h"
+#import "cocoa/coordinates.h"
#import "desktop/tree.h"
#import "desktop/plotters.h"
#import "desktop/history_global_core.h"
-#import "cocoa/coordinates.h"
@implementation TreeView
Modified: trunk/netsurf/cocoa/URLFieldCell.m
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/URLFieldCell.m?rev=...
==============================================================================
--- trunk/netsurf/cocoa/URLFieldCell.m (original)
+++ trunk/netsurf/cocoa/URLFieldCell.m Mon Jan 31 13:12:00 2011
@@ -16,7 +16,7 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-#import "URLFieldCell.h"
+#import "cocoa/URLFieldCell.h"
@interface URLFieldCell ()
Modified: trunk/netsurf/cocoa/bitmap.m
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/bitmap.m?rev=11567&...
==============================================================================
--- trunk/netsurf/cocoa/bitmap.m (original)
+++ trunk/netsurf/cocoa/bitmap.m Mon Jan 31 13:12:00 2011
@@ -18,8 +18,9 @@
#import <Cocoa/Cocoa.h>
+#import "cocoa/bitmap.h"
+
#import "image/bitmap.h"
-#import "cocoa/bitmap.h"
#define BITS_PER_SAMPLE (8)
#define SAMPLES_PER_PIXEL (4)
Modified: trunk/netsurf/cocoa/font.h
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/font.h?rev=11567&r1...
==============================================================================
--- trunk/netsurf/cocoa/font.h (original)
+++ trunk/netsurf/cocoa/font.h Mon Jan 31 13:12:00 2011
@@ -19,6 +19,8 @@
#ifndef COCOA_FONT_H
#define COCOA_FONT_H
+#import "desktop/plot_style.h"
+
void cocoa_draw_string( CGFloat x, CGFloat y, const char *bytes, size_t length, const plot_font_style_t *style );
void cocoa_set_font_scale_factor( float newFactor );
Modified: trunk/netsurf/cocoa/font.m
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/font.m?rev=11567&r1...
==============================================================================
--- trunk/netsurf/cocoa/font.m (original)
+++ trunk/netsurf/cocoa/font.m Mon Jan 31 13:12:00 2011
@@ -18,17 +18,14 @@
#import <Cocoa/Cocoa.h>
-#include <inttypes.h>
-
-#include <assert.h>
-
-#include "css/css.h"
-#include "render/font.h"
-#include "desktop/options.h"
-
-#import "font.h"
-#import "plotter.h"
#import "cocoa/plotter.h"
+#import "cocoa/font.h"
+
+#import "css/css.h"
+#import "desktop/options.h"
+#import "render/font.h"
+#import "desktop/plotters.h"
+
static NSLayoutManager *cocoa_prepare_layout_manager( const char *string, size_t length,
const plot_font_style_t *style );
Modified: trunk/netsurf/cocoa/gui.m
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/gui.m?rev=11567&r1=...
==============================================================================
--- trunk/netsurf/cocoa/gui.m (original)
+++ trunk/netsurf/cocoa/gui.m Mon Jan 31 13:12:00 2011
@@ -20,11 +20,10 @@
#import "cocoa/gui.h"
#import "cocoa/plotter.h"
-
-#import "BrowserView.h"
-#import "BrowserViewController.h"
-#import "BrowserWindowController.h"
-#import "FormSelectMenu.h"
+#import "cocoa/BrowserView.h"
+#import "cocoa/BrowserViewController.h"
+#import "cocoa/BrowserWindowController.h"
+#import "cocoa/FormSelectMenu.h"
#import "desktop/gui.h"
#import "desktop/netsurf.h"
Modified: trunk/netsurf/cocoa/plotter.m
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/plotter.m?rev=11567...
==============================================================================
--- trunk/netsurf/cocoa/plotter.m (original)
+++ trunk/netsurf/cocoa/plotter.m Mon Jan 31 13:12:00 2011
@@ -18,13 +18,13 @@
#include <Cocoa/Cocoa.h>
-#include "desktop/plotters.h"
-#import "desktop/plot_style.h"
-#import "utils/log.h"
-
#import "cocoa/font.h"
#import "cocoa/plotter.h"
#import "cocoa/bitmap.h"
+
+#import "desktop/plotters.h"
+#import "desktop/plot_style.h"
+#import "utils/log.h"
#import "css/utils.h"
static void cocoa_plot_render_path(NSBezierPath *path,const plot_style_t *pstyle);
Modified: trunk/netsurf/cocoa/schedule.m
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/schedule.m?rev=1156...
==============================================================================
--- trunk/netsurf/cocoa/schedule.m (original)
+++ trunk/netsurf/cocoa/schedule.m Mon Jan 31 13:12:00 2011
@@ -16,9 +16,9 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
+#import <Cocoa/Cocoa.h>
+
#import "desktop/browser.h"
-
-#import <Cocoa/Cocoa.h>
@interface ScheduledCallback : NSObject {
void (*callback)( void *userData );
Modified: trunk/netsurf/cocoa/thumbnail.m
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/thumbnail.m?rev=115...
==============================================================================
--- trunk/netsurf/cocoa/thumbnail.m (original)
+++ trunk/netsurf/cocoa/thumbnail.m Mon Jan 31 13:12:00 2011
@@ -16,12 +16,12 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
+#import <Cocoa/Cocoa.h>
+
#import "desktop/browser.h"
#import "desktop/plotters.h"
#import "content/urldb.h"
#import "image/bitmap.h"
-
-#import <Cocoa/Cocoa.h>
/* In platform specific thumbnail.c. */
bool thumbnail_create(struct hlcache_handle *content, struct bitmap *bitmap,
Modified: trunk/netsurf/cocoa/url.m
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/url.m?rev=11567&r1=...
==============================================================================
--- trunk/netsurf/cocoa/url.m (original)
+++ trunk/netsurf/cocoa/url.m Mon Jan 31 13:12:00 2011
@@ -16,11 +16,9 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-#import <stdbool.h>
-#import <stdlib.h>
+#import <Cocoa/Cocoa.h>
+
#import "utils/url.h"
-
-#import <Cocoa/Cocoa.h>
char *url_to_path(const char *url)
Modified: trunk/netsurf/cocoa/utils.m
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/utils.m?rev=11567&r...
==============================================================================
--- trunk/netsurf/cocoa/utils.m (original)
+++ trunk/netsurf/cocoa/utils.m Mon Jan 31 13:12:00 2011
@@ -17,6 +17,7 @@
*/
#import <Cocoa/Cocoa.h>
+
#import "utils/utils.h"
#import "desktop/tree_url_node.h"
12 years, 7 months
r11566 swdr - in /trunk/netsurf/cocoa: BrowserViewController.h BrowserViewController.m res/BrowserWindow.xib
by netsurf@semichrome.net
Author: swdr
Date: Mon Jan 31 12:48:09 2011
New Revision: 11566
URL: http://source.netsurf-browser.org?rev=11566&view=rev
Log:
Added 'Home' button
Modified:
trunk/netsurf/cocoa/BrowserViewController.h
trunk/netsurf/cocoa/BrowserViewController.m
trunk/netsurf/cocoa/res/BrowserWindow.xib
Modified: trunk/netsurf/cocoa/BrowserViewController.h
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/BrowserViewControll...
==============================================================================
--- trunk/netsurf/cocoa/BrowserViewController.h (original)
+++ trunk/netsurf/cocoa/BrowserViewController.h Mon Jan 31 12:48:09 2011
@@ -57,6 +57,8 @@
- (IBAction) backForwardSelected: (id) sender;
+- (IBAction) goHome: (id) sender;
+
- (IBAction) goBack: (id) sender;
- (IBAction) goForward: (id) sender;
- (IBAction) reloadPage: (id) sender;
Modified: trunk/netsurf/cocoa/BrowserViewController.m
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/BrowserViewControll...
==============================================================================
--- trunk/netsurf/cocoa/BrowserViewController.m (original)
+++ trunk/netsurf/cocoa/BrowserViewController.m Mon Jan 31 12:48:09 2011
@@ -111,6 +111,11 @@
}
}
+- (IBAction) goHome: (id) sender;
+{
+ browser_window_go( browser, option_homepage_url, NULL, true );
+}
+
- (IBAction) reloadPage: (id) sender;
{
browser_window_reload( browser, true );
Modified: trunk/netsurf/cocoa/res/BrowserWindow.xib
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/res/BrowserWindow.x...
==============================================================================
--- trunk/netsurf/cocoa/res/BrowserWindow.xib (original)
+++ trunk/netsurf/cocoa/res/BrowserWindow.xib Mon Jan 31 12:48:09 2011
@@ -12,6 +12,7 @@
</object>
<object class="NSMutableArray" key="IBDocument.EditedObjectIDs">
<bool key="EncodedWithXMLCoder">YES</bool>
+ <integer value="2"/>
</object>
<object class="NSArray" key="IBDocument.PluginDependencies">
<bool key="EncodedWithXMLCoder">YES</bool>
@@ -60,6 +61,7 @@
<object class="NSArray" key="dict.sortedKeys">
<bool key="EncodedWithXMLCoder">YES</bool>
<string>6D497003-6D4B-4335-ADCE-368C7CD87371</string>
+ <string>9DB83278-4E60-41F8-8A7C-C0B2E00A552B</string>
<string>BC5CEBFC-2E3B-420C-A75F-BE0760149C45</string>
<string>E2E89C48-DD3F-47A5-9E6C-25985A970F69</string>
<string>NSToolbarCustomizeToolbarItem</string>
@@ -77,9 +79,11 @@
<string key="NSToolbarItemPaletteLabel">History</string>
<nil key="NSToolbarItemToolTip"/>
<object class="NSButton" key="NSToolbarItemView" id="229385913">
- <nil key="NSNextResponder"/>
+ <reference key="NSNextResponder"/>
<int key="NSvFlags">268</int>
<string key="NSFrame">{{8, 14}, {30, 25}}</string>
+ <reference key="NSSuperview"/>
+ <reference key="NSWindow"/>
<bool key="NSEnabled">YES</bool>
<object class="NSButtonCell" key="NSCell" id="296571644">
<int key="NSCellFlags">67239424</int>
@@ -91,7 +95,7 @@
<int key="NSfFlags">1044</int>
</object>
<reference key="NSControlView" ref="229385913"/>
- <int key="NSButtonFlags">918831359</int>
+ <int key="NSButtonFlags">919355647</int>
<int key="NSButtonFlags2">163</int>
<object class="NSCustomResource" key="NSNormalImage" id="235904051">
<string key="NSClassName">NSImage</string>
@@ -114,6 +118,49 @@
<bool key="NSToolbarIsUserRemovable">YES</bool>
<int key="NSToolbarItemVisibilityPriority">0</int>
</object>
+ <object class="NSToolbarItem" id="694471322">
+ <object class="NSMutableString" key="NSToolbarItemIdentifier">
+ <characters key="NS.bytes">9DB83278-4E60-41F8-8A7C-C0B2E00A552B</characters>
+ </object>
+ <string key="NSToolbarItemLabel">Homepage</string>
+ <string key="NSToolbarItemPaletteLabel">Homepage</string>
+ <nil key="NSToolbarItemToolTip"/>
+ <object class="NSButton" key="NSToolbarItemView" id="518219892">
+ <reference key="NSNextResponder"/>
+ <int key="NSvFlags">268</int>
+ <string key="NSFrame">{{18, 14}, {30, 25}}</string>
+ <reference key="NSSuperview"/>
+ <reference key="NSWindow"/>
+ <bool key="NSEnabled">YES</bool>
+ <object class="NSButtonCell" key="NSCell" id="413663381">
+ <int key="NSCellFlags">-2080244224</int>
+ <int key="NSCellFlags2">134217728</int>
+ <string key="NSContents"/>
+ <reference key="NSSupport" ref="770988704"/>
+ <reference key="NSControlView" ref="518219892"/>
+ <int key="NSButtonFlags">-2033434369</int>
+ <int key="NSButtonFlags2">99</int>
+ <object class="NSCustomResource" key="NSNormalImage" id="185416320">
+ <string key="NSClassName">NSImage</string>
+ <string key="NSResourceName">NetSurf</string>
+ </object>
+ <string key="NSAlternateContents"/>
+ <string key="NSKeyEquivalent"/>
+ <int key="NSPeriodicDelay">400</int>
+ <int key="NSPeriodicInterval">75</int>
+ </object>
+ </object>
+ <reference key="NSToolbarItemImage" ref="185416320"/>
+ <nil key="NSToolbarItemTarget"/>
+ <nil key="NSToolbarItemAction"/>
+ <string key="NSToolbarItemMinSize">{30, 25}</string>
+ <string key="NSToolbarItemMaxSize">{30, 25}</string>
+ <bool key="NSToolbarItemEnabled">YES</bool>
+ <bool key="NSToolbarItemAutovalidates">YES</bool>
+ <int key="NSToolbarItemTag">0</int>
+ <bool key="NSToolbarIsUserRemovable">YES</bool>
+ <int key="NSToolbarItemVisibilityPriority">0</int>
+ </object>
<object class="NSToolbarItem" id="685547192">
<object class="NSMutableString" key="NSToolbarItemIdentifier">
<characters key="NS.bytes">BC5CEBFC-2E3B-420C-A75F-BE0760149C45</characters>
@@ -122,9 +169,11 @@
<string key="NSToolbarItemPaletteLabel">Back/Forward</string>
<nil key="NSToolbarItemToolTip"/>
<object class="NSSegmentedControl" key="NSToolbarItemView" id="692457026">
- <nil key="NSNextResponder"/>
+ <reference key="NSNextResponder"/>
<int key="NSvFlags">268</int>
- <string key="NSFrame">{{5, 14}, {71, 25}}</string>
+ <string key="NSFrame">{{7, 14}, {67, 25}}</string>
+ <reference key="NSSuperview"/>
+ <reference key="NSWindow"/>
<bool key="NSEnabled">YES</bool>
<object class="NSSegmentedCell" key="NSCell" id="845979064">
<int key="NSCellFlags">67239424</int>
@@ -138,7 +187,7 @@
<object class="NSMutableArray" key="NSSegmentImages">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="NSSegmentItem">
- <double key="NSSegmentItemWidth">32</double>
+ <double key="NSSegmentItemWidth">30</double>
<object class="NSCustomResource" key="NSSegmentItemImage">
<string key="NSClassName">NSImage</string>
<string key="NSResourceName">NSLeftFacingTriangleTemplate</string>
@@ -148,7 +197,7 @@
<int key="NSSegmentItemImageScaling">0</int>
</object>
<object class="NSSegmentItem">
- <double key="NSSegmentItemWidth">32</double>
+ <double key="NSSegmentItemWidth">30</double>
<object class="NSCustomResource" key="NSSegmentItemImage">
<string key="NSClassName">NSImage</string>
<string key="NSResourceName">NSRightFacingTriangleTemplate</string>
@@ -167,7 +216,7 @@
<nil key="NSToolbarItemImage"/>
<nil key="NSToolbarItemTarget"/>
<nil key="NSToolbarItemAction"/>
- <string key="NSToolbarItemMinSize">{71, 25}</string>
+ <string key="NSToolbarItemMinSize">{67, 25}</string>
<string key="NSToolbarItemMaxSize">{71, 25}</string>
<bool key="NSToolbarItemEnabled">YES</bool>
<bool key="NSToolbarItemAutovalidates">YES</bool>
@@ -183,9 +232,11 @@
<string key="NSToolbarItemPaletteLabel">URL</string>
<nil key="NSToolbarItemToolTip"/>
<object class="NSTextField" key="NSToolbarItemView" id="77748234">
- <nil key="NSNextResponder"/>
+ <reference key="NSNextResponder"/>
<int key="NSvFlags">268</int>
<string key="NSFrame">{{0, 14}, {96, 22}}</string>
+ <reference key="NSSuperview"/>
+ <reference key="NSWindow"/>
<bool key="NSEnabled">YES</bool>
<object class="NSTextFieldCell" key="NSCell" id="1053649244">
<int key="NSCellFlags">-1804468671</int>
@@ -338,6 +389,7 @@
<object class="NSArray" key="NSToolbarIBAllowedItems">
<bool key="EncodedWithXMLCoder">YES</bool>
<reference ref="685547192"/>
+ <reference ref="694471322"/>
<reference ref="16676378"/>
<reference ref="192029103"/>
<reference ref="1012010237"/>
@@ -348,6 +400,7 @@
<object class="NSMutableArray" key="NSToolbarIBDefaultItems">
<bool key="EncodedWithXMLCoder">YES</bool>
<reference ref="685547192"/>
+ <reference ref="694471322"/>
<reference ref="16676378"/>
<reference ref="192029103"/>
</object>
@@ -358,7 +411,7 @@
<string key="NSWindowContentMaxSize">{1.79769e+308, 1.79769e+308}</string>
<string key="NSWindowContentMinSize">{273, 43}</string>
<object class="NSView" key="NSWindowView" id="1006">
- <nil key="NSNextResponder"/>
+ <reference key="NSNextResponder"/>
<int key="NSvFlags">256</int>
<object class="NSMutableArray" key="NSSubviews">
<bool key="EncodedWithXMLCoder">YES</bool>
@@ -426,6 +479,7 @@
</object>
</object>
<string key="NSFrameSize">{774, 554}</string>
+ <reference key="NSSuperview"/>
</object>
<string key="NSScreenRect">{{0, 0}, {1680, 1028}}</string>
<string key="NSMinSize">{273, 97}</string>
@@ -644,6 +698,14 @@
</object>
<int key="connectionID">81</int>
</object>
+ <object class="IBConnectionRecord">
+ <object class="IBActionConnection" key="connection">
+ <string key="label">goHome:</string>
+ <reference key="source" ref="1003"/>
+ <reference key="destination" ref="518219892"/>
+ </object>
+ <int key="connectionID">85</int>
+ </object>
</object>
<object class="IBMutableOrderedSet" key="objectRecords">
<object class="NSArray" key="orderedObjects">
@@ -738,6 +800,7 @@
<reference ref="661775936"/>
<reference ref="685547192"/>
<reference ref="16676378"/>
+ <reference ref="694471322"/>
</object>
<reference key="parent" ref="1005"/>
</object>
@@ -835,6 +898,29 @@
<int key="objectID">76</int>
<reference key="object" ref="296571644"/>
<reference key="parent" ref="229385913"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">84</int>
+ <reference key="object" ref="694471322"/>
+ <object class="NSMutableArray" key="children">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <reference ref="518219892"/>
+ </object>
+ <reference key="parent" ref="71746575"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">82</int>
+ <reference key="object" ref="518219892"/>
+ <object class="NSMutableArray" key="children">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <reference ref="413663381"/>
+ </object>
+ <reference key="parent" ref="694471322"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">83</int>
+ <reference key="object" ref="413663381"/>
+ <reference key="parent" ref="518219892"/>
</object>
</object>
</object>
@@ -875,12 +961,14 @@
<string>72.IBSegmentedControlInspectorSelectedSegmentMetadataKey</string>
<string>75.IBPluginDependency</string>
<string>76.IBPluginDependency</string>
+ <string>82.IBPluginDependency</string>
+ <string>83.IBPluginDependency</string>
</object>
<object class="NSMutableArray" key="dict.values">
<bool key="EncodedWithXMLCoder">YES</bool>
- <string>{{276, 318}, {774, 554}}</string>
- <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
- <string>{{276, 318}, {774, 554}}</string>
+ <string>{{347, 86}, {774, 554}}</string>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <string>{{347, 86}, {774, 554}}</string>
<integer value="1"/>
<string>{196, 240}</string>
<string>{{202, 428}, {480, 270}}</string>
@@ -904,7 +992,7 @@
<object class="NSAffineTransform">
<bytes key="NSTransformStruct">P4AAAL+AAABDiwAAxAVAAA</bytes>
</object>
- <string>{{355, 872}, {616, 0}}</string>
+ <string>{{426, 640}, {616, 0}}</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
@@ -916,7 +1004,9 @@
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
- <integer value="1"/>
+ <integer value="0"/>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
</object>
@@ -937,7 +1027,7 @@
</object>
</object>
<nil key="sourceID"/>
- <int key="maxID">81</int>
+ <int key="maxID">85</int>
</object>
<object class="IBClassDescriber" key="IBDocument.Classes">
<object class="NSMutableArray" key="referencedPartialClassDescriptions">
@@ -960,6 +1050,7 @@
<string>backForwardSelected:</string>
<string>goBack:</string>
<string>goForward:</string>
+ <string>goHome:</string>
<string>navigate:</string>
<string>reloadPage:</string>
<string>stopLoading:</string>
@@ -978,6 +1069,7 @@
<string>id</string>
<string>id</string>
<string>id</string>
+ <string>id</string>
</object>
</object>
<object class="NSMutableDictionary" key="actionInfosByName">
@@ -987,6 +1079,7 @@
<string>backForwardSelected:</string>
<string>goBack:</string>
<string>goForward:</string>
+ <string>goHome:</string>
<string>navigate:</string>
<string>reloadPage:</string>
<string>stopLoading:</string>
@@ -1006,6 +1099,10 @@
</object>
<object class="IBActionInfo">
<string key="name">goForward:</string>
+ <string key="candidateClassName">id</string>
+ </object>
+ <object class="IBActionInfo">
+ <string key="name">goHome:</string>
<string key="candidateClassName">id</string>
</object>
<object class="IBActionInfo">
@@ -1279,6 +1376,7 @@
<string>NSMenuMixedState</string>
<string>NSRightFacingTriangleTemplate</string>
<string>NSToolbarCustomizeToolbarItemImage</string>
+ <string>NetSurf</string>
</object>
<object class="NSMutableArray" key="dict.values">
<bool key="EncodedWithXMLCoder">YES</bool>
@@ -1288,6 +1386,7 @@
<string>{7, 2}</string>
<string>{9, 9}</string>
<string>{32, 32}</string>
+ <string>{512, 512}</string>
</object>
</object>
</data>
12 years, 7 months
r11565 swdr - in /trunk/netsurf/cocoa: Makefile.target NetSurf.xcodeproj/project.pbxproj NetSurfAppDelegate.h NetSurfAppDelegate.m PreferencesWindowController.h PreferencesWindowController.m res/MainMenu.xib res/PreferencesWindow.xib
by netsurf@semichrome.net
Author: swdr
Date: Mon Jan 31 12:38:03 2011
New Revision: 11565
URL: http://source.netsurf-browser.org?rev=11565&view=rev
Log:
Implemented preferences window.
Added:
trunk/netsurf/cocoa/PreferencesWindowController.h
- copied, changed from r11564, trunk/netsurf/cocoa/NetSurfAppDelegate.h
trunk/netsurf/cocoa/PreferencesWindowController.m
trunk/netsurf/cocoa/res/PreferencesWindow.xib
Modified:
trunk/netsurf/cocoa/Makefile.target
trunk/netsurf/cocoa/NetSurf.xcodeproj/project.pbxproj
trunk/netsurf/cocoa/NetSurfAppDelegate.h
trunk/netsurf/cocoa/NetSurfAppDelegate.m
trunk/netsurf/cocoa/res/MainMenu.xib
Modified: trunk/netsurf/cocoa/Makefile.target
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/Makefile.target?rev...
==============================================================================
--- trunk/netsurf/cocoa/Makefile.target (original)
+++ trunk/netsurf/cocoa/Makefile.target Mon Jan 31 12:38:03 2011
@@ -71,6 +71,7 @@
DownloadWindowController.m \
NetSurfAppDelegate.m \
NetsurfApp.m \
+ PreferencesWindowController.m \
ScrollableView.m \
SearchWindowController.m \
URLFieldCell.m \
@@ -115,7 +116,7 @@
EXETARGET := NetSurf
-S_XIBS := MainMenu.xib Browser.xib BrowserWindow.xib DownloadWindow.xib SearchWindow.xib
+S_XIBS := MainMenu.xib Browser.xib BrowserWindow.xib DownloadWindow.xib SearchWindow.xib PreferencesWindow.xib
R_RESOURCES := default.css adblock.css quirks.css NetSurf.icns
R_RESOURCES := $(addprefix cocoa/res/,$(R_RESOURCES))
Modified: trunk/netsurf/cocoa/NetSurf.xcodeproj/project.pbxproj
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/NetSurf.xcodeproj/p...
==============================================================================
--- trunk/netsurf/cocoa/NetSurf.xcodeproj/project.pbxproj (original)
+++ trunk/netsurf/cocoa/NetSurf.xcodeproj/project.pbxproj Mon Jan 31 12:38:03 2011
@@ -171,6 +171,9 @@
2612269612D7AEBE00E10F91 /* fr */ = {isa = PBXFileReference; lastKnownFileType = text; name = fr; path = fr.lproj/Messages; sourceTree = "<group>"; };
2622F1D512DCD84600CD5A62 /* TreeView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TreeView.h; sourceTree = "<group>"; };
2622F1D612DCD84600CD5A62 /* TreeView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TreeView.m; sourceTree = "<group>"; };
+ 2625095012F72A8F0090D236 /* PreferencesWindow.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = PreferencesWindow.xib; sourceTree = "<group>"; };
+ 2625095112F72AA70090D236 /* PreferencesWindowController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PreferencesWindowController.h; sourceTree = "<group>"; };
+ 2625095212F72AA70090D236 /* PreferencesWindowController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PreferencesWindowController.m; sourceTree = "<group>"; };
2636299412F699250048542C /* NetSurf.app */ = {isa = PBXFileReference; lastKnownFileType = wrapper.application; name = NetSurf.app; path = ../NetSurf.app; sourceTree = SOURCE_ROOT; };
263629B312F69A290048542C /* Makefile.config */ = {isa = PBXFileReference; explicitFileType = sourcecode.make; fileEncoding = 4; name = Makefile.config; path = ../Makefile.config; sourceTree = SOURCE_ROOT; };
263629B412F69A290048542C /* Makefile.defaults */ = {isa = PBXFileReference; explicitFileType = sourcecode.make; fileEncoding = 4; name = Makefile.defaults; path = ../Makefile.defaults; sourceTree = SOURCE_ROOT; };
@@ -527,6 +530,8 @@
265F310F12D663C20048B600 /* Resources */,
26CDCEB212E702D8004FC66B /* PSMTabBarControl */,
265F30AB12D6637E0048B600 /* Prefix.pch */,
+ 2625095112F72AA70090D236 /* PreferencesWindowController.h */,
+ 2625095212F72AA70090D236 /* PreferencesWindowController.m */,
);
name = "Cocoa Frontend";
sourceTree = "<group>";
@@ -545,6 +550,7 @@
26AFEAF012E042F9005AD082 /* DownloadWindow.xib */,
26CDCFF212E70AD1004FC66B /* BrowserWindow.xib */,
2666DC5B12F6D1770045E8B6 /* SearchWindow.xib */,
+ 2625095012F72A8F0090D236 /* PreferencesWindow.xib */,
);
name = Resources;
path = res;
Modified: trunk/netsurf/cocoa/NetSurfAppDelegate.h
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/NetSurfAppDelegate....
==============================================================================
--- trunk/netsurf/cocoa/NetSurfAppDelegate.h (original)
+++ trunk/netsurf/cocoa/NetSurfAppDelegate.h Mon Jan 31 12:38:03 2011
@@ -19,17 +19,22 @@
#import <Cocoa/Cocoa.h>
@class SearchWindowController;
+@class PreferencesWindowController;
@interface NetSurfAppDelegate : NSObject {
NSWindow *historyWindow;
SearchWindowController *search;
+ PreferencesWindowController *preferences;
}
@property (readwrite, retain, nonatomic) IBOutlet NSWindow *historyWindow;
@property (readwrite, retain, nonatomic) SearchWindowController *search;
+@property (readwrite, retain, nonatomic) PreferencesWindowController *preferences;
- (IBAction) showSearchWindow: (id) sender;
- (IBAction) searchForward: (id) sender;
- (IBAction) searchBackward: (id) sender;
+- (IBAction) showPreferences: (id) sender;
+
@end
Modified: trunk/netsurf/cocoa/NetSurfAppDelegate.m
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/NetSurfAppDelegate....
==============================================================================
--- trunk/netsurf/cocoa/NetSurfAppDelegate.m (original)
+++ trunk/netsurf/cocoa/NetSurfAppDelegate.m Mon Jan 31 12:38:03 2011
@@ -18,6 +18,7 @@
#import "NetSurfAppDelegate.h"
#import "cocoa/SearchWindowController.h"
+#import "cocoa/PreferencesWindowController.h"
#import "desktop/browser.h"
#import "desktop/options.h"
@@ -33,6 +34,7 @@
@synthesize historyWindow;
@synthesize search;
+@synthesize preferences;
- (void) newDocument: (id) sender;
{
@@ -92,6 +94,14 @@
return YES;
}
+- (IBAction) showPreferences: (id) sender;
+{
+ if (preferences == nil) {
+ [self setPreferences: [[[PreferencesWindowController alloc] init] autorelease]];
+ }
+ [preferences showWindow: sender];
+}
+
// Application delegate methods
- (BOOL) applicationOpenUntitledFile: (NSApplication *)sender;
Copied: trunk/netsurf/cocoa/PreferencesWindowController.h (from r11564, trunk/netsurf/cocoa/NetSurfAppDelegate.h)
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/PreferencesWindowCo...
==============================================================================
--- trunk/netsurf/cocoa/NetSurfAppDelegate.h (original)
+++ trunk/netsurf/cocoa/PreferencesWindowController.h Mon Jan 31 12:38:03 2011
@@ -16,20 +16,14 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
+
#import <Cocoa/Cocoa.h>
-@class SearchWindowController;
-@interface NetSurfAppDelegate : NSObject {
- NSWindow *historyWindow;
- SearchWindowController *search;
-}
+@interface PreferencesWindowController : NSWindowController
-@property (readwrite, retain, nonatomic) IBOutlet NSWindow *historyWindow;
-@property (readwrite, retain, nonatomic) SearchWindowController *search;
+@property (readwrite, copy, nonatomic) NSString *homepageURL;
-- (IBAction) showSearchWindow: (id) sender;
-- (IBAction) searchForward: (id) sender;
-- (IBAction) searchBackward: (id) sender;
+- (IBAction) useCurrentPageAsHomepage: (id) sender;
@end
Added: trunk/netsurf/cocoa/PreferencesWindowController.m
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/PreferencesWindowCo...
==============================================================================
--- trunk/netsurf/cocoa/PreferencesWindowController.m (added)
+++ trunk/netsurf/cocoa/PreferencesWindowController.m Mon Jan 31 12:38:03 2011
@@ -1,0 +1,58 @@
+/*
+ * Copyright 2011 Sven Weidauer <sven.weidauer(a)gmail.com>
+ *
+ * This file is part of NetSurf, http://www.netsurf-browser.org/
+ *
+ * NetSurf is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; version 2 of the License.
+ *
+ * NetSurf is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+
+#import "cocoa/PreferencesWindowController.h"
+#import "cocoa/NetsurfApp.h"
+#import "cocoa/gui.h"
+#import "cocoa/BrowserViewController.h"
+
+#import "desktop/browser.h"
+#import "content/content.h"
+#import "desktop/options.h"
+
+@implementation PreferencesWindowController
+
+- init;
+{
+ if ((self = [super initWithWindowNibName: @"PreferencesWindow"]) == nil) return nil;
+
+ return self;
+}
+
+- (IBAction) useCurrentPageAsHomepage: (id) sender;
+{
+ struct browser_window *bw = [[(NetSurfApp *)NSApp frontTab] browser];
+ const char *url = content_get_url( bw->current_content );
+ [self setHomepageURL: [NSString stringWithUTF8String: url]];
+}
+
+- (void) setHomepageURL: (NSString *) newUrl;
+{
+ free( option_homepage_url );
+ option_homepage_url = strdup( [newUrl UTF8String] );
+ [[NSUserDefaults standardUserDefaults] setObject: newUrl forKey: kHomepageURLOption];
+ [[NSUserDefaults standardUserDefaults] synchronize];
+}
+
+- (NSString *) homepageURL;
+{
+ return [NSString stringWithUTF8String: option_homepage_url];
+}
+
+@end
Modified: trunk/netsurf/cocoa/res/MainMenu.xib
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/res/MainMenu.xib?re...
==============================================================================
--- trunk/netsurf/cocoa/res/MainMenu.xib (original)
+++ trunk/netsurf/cocoa/res/MainMenu.xib Mon Jan 31 12:38:03 2011
@@ -12,7 +12,7 @@
</object>
<object class="NSMutableArray" key="IBDocument.EditedObjectIDs">
<bool key="EncodedWithXMLCoder">YES</bool>
- <integer value="81"/>
+ <integer value="57"/>
</object>
<object class="NSArray" key="IBDocument.PluginDependencies">
<bool key="EncodedWithXMLCoder">YES</bool>
@@ -1034,6 +1034,14 @@
<reference key="destination" ref="776162233"/>
</object>
<int key="connectionID">844</int>
+ </object>
+ <object class="IBConnectionRecord">
+ <object class="IBActionConnection" key="connection">
+ <string key="label">showPreferences:</string>
+ <reference key="source" ref="1026802243"/>
+ <reference key="destination" ref="609285721"/>
+ </object>
+ <int key="connectionID">845</int>
</object>
</object>
<object class="IBMutableOrderedSet" key="objectRecords">
@@ -1872,7 +1880,7 @@
</object>
</object>
<nil key="sourceID"/>
- <int key="maxID">844</int>
+ <int key="maxID">845</int>
</object>
<object class="IBClassDescriber" key="IBDocument.Classes">
<object class="NSMutableArray" key="referencedPartialClassDescriptions">
@@ -2108,6 +2116,7 @@
<bool key="EncodedWithXMLCoder">YES</bool>
<string>searchBackward:</string>
<string>searchForward:</string>
+ <string>showPreferences:</string>
<string>showSearchWindow:</string>
</object>
<object class="NSMutableArray" key="dict.values">
@@ -2115,6 +2124,7 @@
<string>id</string>
<string>id</string>
<string>id</string>
+ <string>id</string>
</object>
</object>
<object class="NSMutableDictionary" key="actionInfosByName">
@@ -2123,6 +2133,7 @@
<bool key="EncodedWithXMLCoder">YES</bool>
<string>searchBackward:</string>
<string>searchForward:</string>
+ <string>showPreferences:</string>
<string>showSearchWindow:</string>
</object>
<object class="NSMutableArray" key="dict.values">
@@ -2133,6 +2144,10 @@
</object>
<object class="IBActionInfo">
<string key="name">searchForward:</string>
+ <string key="candidateClassName">id</string>
+ </object>
+ <object class="IBActionInfo">
+ <string key="name">showPreferences:</string>
<string key="candidateClassName">id</string>
</object>
<object class="IBActionInfo">
Added: trunk/netsurf/cocoa/res/PreferencesWindow.xib
URL: http://source.netsurf-browser.org/trunk/netsurf/cocoa/res/PreferencesWind...
==============================================================================
--- trunk/netsurf/cocoa/res/PreferencesWindow.xib (added)
+++ trunk/netsurf/cocoa/res/PreferencesWindow.xib Mon Jan 31 12:38:03 2011
@@ -1,0 +1,531 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<archive type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="7.10">
+ <data>
+ <int key="IBDocument.SystemTarget">1060</int>
+ <string key="IBDocument.SystemVersion">10J567</string>
+ <string key="IBDocument.InterfaceBuilderVersion">804</string>
+ <string key="IBDocument.AppKitVersion">1038.35</string>
+ <string key="IBDocument.HIToolboxVersion">462.00</string>
+ <object class="NSMutableDictionary" key="IBDocument.PluginVersions">
+ <string key="NS.key.0">com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <string key="NS.object.0">804</string>
+ </object>
+ <object class="NSMutableArray" key="IBDocument.EditedObjectIDs">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <integer value="2"/>
+ </object>
+ <object class="NSArray" key="IBDocument.PluginDependencies">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ </object>
+ <object class="NSMutableDictionary" key="IBDocument.Metadata">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <object class="NSArray" key="dict.sortedKeys" id="0">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ </object>
+ <object class="NSMutableArray" key="dict.values">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ </object>
+ </object>
+ <object class="NSMutableArray" key="IBDocument.RootObjects" id="1000">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <object class="NSCustomObject" id="1001">
+ <string key="NSClassName">PreferencesWindowController</string>
+ </object>
+ <object class="NSCustomObject" id="1003">
+ <string key="NSClassName">FirstResponder</string>
+ </object>
+ <object class="NSCustomObject" id="1004">
+ <string key="NSClassName">NSApplication</string>
+ </object>
+ <object class="NSWindowTemplate" id="1005">
+ <int key="NSWindowStyleMask">7</int>
+ <int key="NSWindowBacking">2</int>
+ <string key="NSWindowRect">{{196, 362}, {455, 148}}</string>
+ <int key="NSWTFlags">1618477056</int>
+ <string key="NSWindowTitle">Preferences</string>
+ <string key="NSWindowClass">NSWindow</string>
+ <nil key="NSViewClass"/>
+ <string key="NSWindowContentMaxSize">{1.79769e+308, 1.79769e+308}</string>
+ <object class="NSView" key="NSWindowView" id="1006">
+ <reference key="NSNextResponder"/>
+ <int key="NSvFlags">256</int>
+ <object class="NSMutableArray" key="NSSubviews">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <object class="NSTextField" id="343066491">
+ <reference key="NSNextResponder" ref="1006"/>
+ <int key="NSvFlags">268</int>
+ <string key="NSFrame">{{98, 106}, {337, 22}}</string>
+ <reference key="NSSuperview" ref="1006"/>
+ <bool key="NSEnabled">YES</bool>
+ <object class="NSTextFieldCell" key="NSCell" id="218234675">
+ <int key="NSCellFlags">-1804468671</int>
+ <int key="NSCellFlags2">272630784</int>
+ <string key="NSContents"/>
+ <object class="NSFont" key="NSSupport" id="1015231142">
+ <string key="NSName">LucidaGrande</string>
+ <double key="NSSize">13</double>
+ <int key="NSfFlags">1044</int>
+ </object>
+ <reference key="NSControlView" ref="343066491"/>
+ <bool key="NSDrawsBackground">YES</bool>
+ <object class="NSColor" key="NSBackgroundColor">
+ <int key="NSColorSpace">6</int>
+ <string key="NSCatalogName">System</string>
+ <string key="NSColorName">textBackgroundColor</string>
+ <object class="NSColor" key="NSColor">
+ <int key="NSColorSpace">3</int>
+ <bytes key="NSWhite">MQA</bytes>
+ </object>
+ </object>
+ <object class="NSColor" key="NSTextColor">
+ <int key="NSColorSpace">6</int>
+ <string key="NSCatalogName">System</string>
+ <string key="NSColorName">textColor</string>
+ <object class="NSColor" key="NSColor" id="751207648">
+ <int key="NSColorSpace">3</int>
+ <bytes key="NSWhite">MAA</bytes>
+ </object>
+ </object>
+ </object>
+ </object>
+ <object class="NSTextField" id="662601838">
+ <reference key="NSNextResponder" ref="1006"/>
+ <int key="NSvFlags">268</int>
+ <string key="NSFrame">{{17, 108}, {76, 17}}</string>
+ <reference key="NSSuperview" ref="1006"/>
+ <bool key="NSEnabled">YES</bool>
+ <object class="NSTextFieldCell" key="NSCell" id="633183289">
+ <int key="NSCellFlags">68288064</int>
+ <int key="NSCellFlags2">272630784</int>
+ <string key="NSContents">Homepage:</string>
+ <reference key="NSSupport" ref="1015231142"/>
+ <reference key="NSControlView" ref="662601838"/>
+ <object class="NSColor" key="NSBackgroundColor">
+ <int key="NSColorSpace">6</int>
+ <string key="NSCatalogName">System</string>
+ <string key="NSColorName">controlColor</string>
+ <object class="NSColor" key="NSColor">
+ <int key="NSColorSpace">3</int>
+ <bytes key="NSWhite">MC42NjY2NjY2NjY3AA</bytes>
+ </object>
+ </object>
+ <object class="NSColor" key="NSTextColor">
+ <int key="NSColorSpace">6</int>
+ <string key="NSCatalogName">System</string>
+ <string key="NSColorName">controlTextColor</string>
+ <reference key="NSColor" ref="751207648"/>
+ </object>
+ </object>
+ </object>
+ <object class="NSButton" id="272890940">
+ <reference key="NSNextResponder" ref="1006"/>
+ <int key="NSvFlags">268</int>
+ <string key="NSFrame">{{293, 70}, {148, 32}}</string>
+ <reference key="NSSuperview" ref="1006"/>
+ <bool key="NSEnabled">YES</bool>
+ <object class="NSButtonCell" key="NSCell" id="136693114">
+ <int key="NSCellFlags">67239424</int>
+ <int key="NSCellFlags2">134217728</int>
+ <string key="NSContents">Use current page</string>
+ <reference key="NSSupport" ref="1015231142"/>
+ <reference key="NSControlView" ref="272890940"/>
+ <int key="NSButtonFlags">-2038284033</int>
+ <int key="NSButtonFlags2">129</int>
+ <string key="NSAlternateContents"/>
+ <string key="NSKeyEquivalent"/>
+ <int key="NSPeriodicDelay">200</int>
+ <int key="NSPeriodicInterval">25</int>
+ </object>
+ </object>
+ <object class="NSButton" id="748375959">
+ <reference key="NSNextResponder" ref="1006"/>
+ <int key="NSvFlags">268</int>
+ <string key="NSFrame">{{96, 38}, {234, 18}}</string>
+ <reference key="NSSuperview" ref="1006"/>
+ <bool key="NSEnabled">YES</bool>
+ <object class="NSButtonCell" key="NSCell" id="497902592">
+ <int key="NSCellFlags">-2080244224</int>
+ <int key="NSCellFlags2">0</int>
+ <string key="NSContents">Cancel downloads without asking</string>
+ <reference key="NSSupport" ref="1015231142"/>
+ <reference key="NSControlView" ref="748375959"/>
+ <int key="NSButtonFlags">1211912703</int>
+ <int key="NSButtonFlags2">2</int>
+ <object class="NSCustomResource" key="NSNormalImage" id="118883570">
+ <string key="NSClassName">NSImage</string>
+ <string key="NSResourceName">NSSwitch</string>
+ </object>
+ <object class="NSButtonImageSource" key="NSAlternateImage" id="21608943">
+ <string key="NSImageName">NSSwitch</string>
+ </object>
+ <string key="NSAlternateContents"/>
+ <string key="NSKeyEquivalent"/>
+ <int key="NSPeriodicDelay">200</int>
+ <int key="NSPeriodicInterval">25</int>
+ </object>
+ </object>
+ <object class="NSButton" id="832107887">
+ <reference key="NSNextResponder" ref="1006"/>
+ <int key="NSvFlags">268</int>
+ <string key="NSFrame">{{96, 18}, {241, 18}}</string>
+ <reference key="NSSuperview" ref="1006"/>
+ <bool key="NSEnabled">YES</bool>
+ <object class="NSButtonCell" key="NSCell" id="616812964">
+ <int key="NSCellFlags">-2080244224</int>
+ <int key="NSCellFlags2">0</int>
+ <string key="NSContents">Close multiple tabs without asking</string>
+ <reference key="NSSupport" ref="1015231142"/>
+ <reference key="NSControlView" ref="832107887"/>
+ <int key="NSButtonFlags">1211912703</int>
+ <int key="NSButtonFlags2">2</int>
+ <reference key="NSNormalImage" ref="118883570"/>
+ <reference key="NSAlternateImage" ref="21608943"/>
+ <string key="NSAlternateContents"/>
+ <string key="NSKeyEquivalent"/>
+ <int key="NSPeriodicDelay">200</int>
+ <int key="NSPeriodicInterval">25</int>
+ </object>
+ </object>
+ </object>
+ <string key="NSFrameSize">{455, 148}</string>
+ <reference key="NSSuperview"/>
+ </object>
+ <string key="NSScreenRect">{{0, 0}, {1680, 1028}}</string>
+ <string key="NSMaxSize">{1.79769e+308, 1.79769e+308}</string>
+ </object>
+ <object class="NSUserDefaultsController" id="562818373">
+ <bool key="NSSharedInstance">YES</bool>
+ </object>
+ </object>
+ <object class="IBObjectContainer" key="IBDocument.Objects">
+ <object class="NSMutableArray" key="connectionRecords">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <object class="IBConnectionRecord">
+ <object class="IBOutletConnection" key="connection">
+ <string key="label">window</string>
+ <reference key="source" ref="1001"/>
+ <reference key="destination" ref="1005"/>
+ </object>
+ <int key="connectionID">3</int>
+ </object>
+ <object class="IBConnectionRecord">
+ <object class="IBBindingConnection" key="connection">
+ <string key="label">value: values.AlwaysCancelDownload</string>
+ <reference key="source" ref="748375959"/>
+ <reference key="destination" ref="562818373"/>
+ <object class="NSNibBindingConnector" key="connector">
+ <reference key="NSSource" ref="748375959"/>
+ <reference key="NSDestination" ref="562818373"/>
+ <string key="NSLabel">value: values.AlwaysCancelDownload</string>
+ <string key="NSBinding">value</string>
+ <string key="NSKeyPath">values.AlwaysCancelDownload</string>
+ <int key="NSNibBindingConnectorVersion">2</int>
+ </object>
+ </object>
+ <int key="connectionID">21</int>
+ </object>
+ <object class="IBConnectionRecord">
+ <object class="IBBindingConnection" key="connection">
+ <string key="label">value: values.AlwaysCloseMultipleTabs</string>
+ <reference key="source" ref="832107887"/>
+ <reference key="destination" ref="562818373"/>
+ <object class="NSNibBindingConnector" key="connector">
+ <reference key="NSSource" ref="832107887"/>
+ <reference key="NSDestination" ref="562818373"/>
+ <string key="NSLabel">value: values.AlwaysCloseMultipleTabs</string>
+ <string key="NSBinding">value</string>
+ <string key="NSKeyPath">values.AlwaysCloseMultipleTabs</string>
+ <int key="NSNibBindingConnectorVersion">2</int>
+ </object>
+ </object>
+ <int key="connectionID">22</int>
+ </object>
+ <object class="IBConnectionRecord">
+ <object class="IBActionConnection" key="connection">
+ <string key="label">useCurrentPageAsHomepage:</string>
+ <reference key="source" ref="1001"/>
+ <reference key="destination" ref="272890940"/>
+ </object>
+ <int key="connectionID">23</int>
+ </object>
+ <object class="IBConnectionRecord">
+ <object class="IBBindingConnection" key="connection">
+ <string key="label">value: homepageURL</string>
+ <reference key="source" ref="343066491"/>
+ <reference key="destination" ref="1001"/>
+ <object class="NSNibBindingConnector" key="connector">
+ <reference key="NSSource" ref="343066491"/>
+ <reference key="NSDestination" ref="1001"/>
+ <string key="NSLabel">value: homepageURL</string>
+ <string key="NSBinding">value</string>
+ <string key="NSKeyPath">homepageURL</string>
+ <int key="NSNibBindingConnectorVersion">2</int>
+ </object>
+ </object>
+ <int key="connectionID">25</int>
+ </object>
+ </object>
+ <object class="IBMutableOrderedSet" key="objectRecords">
+ <object class="NSArray" key="orderedObjects">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <object class="IBObjectRecord">
+ <int key="objectID">0</int>
+ <reference key="object" ref="0"/>
+ <reference key="children" ref="1000"/>
+ <nil key="parent"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">-2</int>
+ <reference key="object" ref="1001"/>
+ <reference key="parent" ref="0"/>
+ <string key="objectName">File's Owner</string>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">-1</int>
+ <reference key="object" ref="1003"/>
+ <reference key="parent" ref="0"/>
+ <string key="objectName">First Responder</string>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">-3</int>
+ <reference key="object" ref="1004"/>
+ <reference key="parent" ref="0"/>
+ <string key="objectName">Application</string>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">1</int>
+ <reference key="object" ref="1005"/>
+ <object class="NSMutableArray" key="children">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <reference ref="1006"/>
+ </object>
+ <reference key="parent" ref="0"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">2</int>
+ <reference key="object" ref="1006"/>
+ <object class="NSMutableArray" key="children">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <reference ref="343066491"/>
+ <reference ref="662601838"/>
+ <reference ref="272890940"/>
+ <reference ref="748375959"/>
+ <reference ref="832107887"/>
+ </object>
+ <reference key="parent" ref="1005"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">9</int>
+ <reference key="object" ref="343066491"/>
+ <object class="NSMutableArray" key="children">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <reference ref="218234675"/>
+ </object>
+ <reference key="parent" ref="1006"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">10</int>
+ <reference key="object" ref="218234675"/>
+ <reference key="parent" ref="343066491"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">11</int>
+ <reference key="object" ref="662601838"/>
+ <object class="NSMutableArray" key="children">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <reference ref="633183289"/>
+ </object>
+ <reference key="parent" ref="1006"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">12</int>
+ <reference key="object" ref="633183289"/>
+ <reference key="parent" ref="662601838"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">13</int>
+ <reference key="object" ref="272890940"/>
+ <object class="NSMutableArray" key="children">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <reference ref="136693114"/>
+ </object>
+ <reference key="parent" ref="1006"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">14</int>
+ <reference key="object" ref="136693114"/>
+ <reference key="parent" ref="272890940"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">15</int>
+ <reference key="object" ref="748375959"/>
+ <object class="NSMutableArray" key="children">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <reference ref="497902592"/>
+ </object>
+ <reference key="parent" ref="1006"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">16</int>
+ <reference key="object" ref="497902592"/>
+ <reference key="parent" ref="748375959"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">17</int>
+ <reference key="object" ref="832107887"/>
+ <object class="NSMutableArray" key="children">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <reference ref="616812964"/>
+ </object>
+ <reference key="parent" ref="1006"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">18</int>
+ <reference key="object" ref="616812964"/>
+ <reference key="parent" ref="832107887"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">19</int>
+ <reference key="object" ref="562818373"/>
+ <reference key="parent" ref="0"/>
+ </object>
+ </object>
+ </object>
+ <object class="NSMutableDictionary" key="flattenedProperties">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <object class="NSArray" key="dict.sortedKeys">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <string>1.IBEditorWindowLastContentRect</string>
+ <string>1.IBPluginDependency</string>
+ <string>1.IBWindowTemplateEditedContentRect</string>
+ <string>1.NSWindowTemplate.visibleAtLaunch</string>
+ <string>1.WindowOrigin</string>
+ <string>1.editorWindowContentRectSynchronizationRect</string>
+ <string>10.IBPluginDependency</string>
+ <string>11.IBPluginDependency</string>
+ <string>11.IBViewBoundsToFrameTransform</string>
+ <string>12.IBPluginDependency</string>
+ <string>13.IBPluginDependency</string>
+ <string>13.IBViewBoundsToFrameTransform</string>
+ <string>14.IBPluginDependency</string>
+ <string>15.IBPluginDependency</string>
+ <string>16.IBPluginDependency</string>
+ <string>17.IBPluginDependency</string>
+ <string>17.IBViewBoundsToFrameTransform</string>
+ <string>18.IBPluginDependency</string>
+ <string>2.IBPluginDependency</string>
+ <string>9.IBPluginDependency</string>
+ <string>9.IBViewBoundsToFrameTransform</string>
+ </object>
+ <object class="NSMutableArray" key="dict.values">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <string>{{222, 133}, {455, 148}}</string>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <string>{{222, 133}, {455, 148}}</string>
+ <integer value="1"/>
+ <string>{196, 240}</string>
+ <string>{{202, 428}, {480, 270}}</string>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <object class="NSAffineTransform">
+ <bytes key="NSTransformStruct">P4AAAL+AAABCYAAAw2sAAA</bytes>
+ </object>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <object class="NSAffineTransform">
+ <bytes key="NSTransformStruct">P4AAAL+AAABClgAAw3wAAA</bytes>
+ </object>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <object class="NSAffineTransform">
+ <bytes key="NSTransformStruct">P4AAAL+AAABCwAAAwggAAA</bytes>
+ </object>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <string>com.apple.InterfaceBuilder.CocoaPlugin</string>
+ <object class="NSAffineTransform">
+ <bytes key="NSTransformStruct">P4AAAL+AAABDSQAAw2sAAA</bytes>
+ </object>
+ </object>
+ </object>
+ <object class="NSMutableDictionary" key="unlocalizedProperties">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <reference key="dict.sortedKeys" ref="0"/>
+ <object class="NSMutableArray" key="dict.values">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ </object>
+ </object>
+ <nil key="activeLocalization"/>
+ <object class="NSMutableDictionary" key="localizations">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <reference key="dict.sortedKeys" ref="0"/>
+ <object class="NSMutableArray" key="dict.values">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ </object>
+ </object>
+ <nil key="sourceID"/>
+ <int key="maxID">25</int>
+ </object>
+ <object class="IBClassDescriber" key="IBDocument.Classes">
+ <object class="NSMutableArray" key="referencedPartialClassDescriptions">
+ <bool key="EncodedWithXMLCoder">YES</bool>
+ <object class="IBPartialClassDescription">
+ <string key="className">NSApplication</string>
+ <object class="IBClassDescriptionSource" key="sourceIdentifier">
+ <string key="majorKey">IBProjectSource</string>
+ <string key="minorKey">PSMTabBarControl/PSMTabDragAssistant.h</string>
+ </object>
+ </object>
+ <object class="IBPartialClassDescription">
+ <string key="className">NSObject</string>
+ <object class="IBClassDescriptionSource" key="sourceIdentifier">
+ <string key="majorKey">IBProjectSource</string>
+ <string key="minorKey">PSMTabBarControl/PSMTabBarCell.h</string>
+ </object>
+ </object>
+ <object class="IBPartialClassDescription">
+ <string key="className">NSObject</string>
+ <object class="IBClassDescriptionSource" key="sourceIdentifier">
+ <string key="majorKey">IBProjectSource</string>
+ <string key="minorKey">PSMTabBarControl/PSMTabBarControl.h</string>
+ </object>
+ </object>
+ <object class="IBPartialClassDescription">
+ <string key="className">PreferencesWindowController</string>
+ <string key="superclassName">NSWindowController</string>
+ <object class="NSMutableDictionary" key="actions">
+ <string key="NS.key.0">useCurrentPageAsHomepage:</string>
+ <string key="NS.object.0">id</string>
+ </object>
+ <object class="NSMutableDictionary" key="actionInfosByName">
+ <string key="NS.key.0">useCurrentPageAsHomepage:</string>
+ <object class="IBActionInfo" key="NS.object.0">
+ <string key="name">useCurrentPageAsHomepage:</string>
+ <string key="candidateClassName">id</string>
+ </object>
+ </object>
+ <object class="IBClassDescriptionSource" key="sourceIdentifier">
+ <string key="majorKey">IBProjectSource</string>
+ <string key="minorKey">PreferencesWindowController.h</string>
+ </object>
+ </object>
+ </object>
+ </object>
+ <int key="IBDocument.localizationMode">0</int>
+ <string key="IBDocument.TargetRuntimeIdentifier">IBCocoaFramework</string>
+ <object class="NSMutableDictionary" key="IBDocument.PluginDeclaredDevelopmentDependencies">
+ <string key="NS.key.0">com.apple.InterfaceBuilder.CocoaPlugin.InterfaceBuilder3</string>
+ <integer value="3000" key="NS.object.0"/>
+ </object>
+ <bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool>
+ <string key="IBDocument.LastKnownRelativeProjectPath">../NetSurf.xcodeproj</string>
+ <int key="IBDocument.defaultPropertyAccessControl">3</int>
+ <object class="NSMutableDictionary" key="IBDocument.LastKnownImageSizes">
+ <string key="NS.key.0">NSSwitch</string>
+ <string key="NS.object.0">{15, 15}</string>
+ </object>
+ </data>
+</archive>
12 years, 7 months