Gitweb links:

...log 
http://git.netsurf-browser.org/netsurf.git/shortlog/246ab6d9ff7504cdc7bf88efe1d4aca987b5c095
...commit 
http://git.netsurf-browser.org/netsurf.git/commit/246ab6d9ff7504cdc7bf88efe1d4aca987b5c095
...tree 
http://git.netsurf-browser.org/netsurf.git/tree/246ab6d9ff7504cdc7bf88efe1d4aca987b5c095

The branch, master has been updated
       via  246ab6d9ff7504cdc7bf88efe1d4aca987b5c095 (commit)
      from  6da3b3102c013b18b6f490d9030e5c2be531fe42 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commitdiff 
http://git.netsurf-browser.org/netsurf.git/commit/?id=246ab6d9ff7504cdc7bf88efe1d4aca987b5c095
commit 246ab6d9ff7504cdc7bf88efe1d4aca987b5c095
Author: Vincent Sanders <[email protected]>
Commit: Vincent Sanders <[email protected]>

    allow beos frontend to make clipboard functions private.
    
    reduces the unecessary export of clipboard functions in beos frontend
    and also removes inclusion of unecessary headers.

diff --git a/beos/gui.cpp b/beos/gui.cpp
index 4fd2ecf..95b1597 100644
--- a/beos/gui.cpp
+++ b/beos/gui.cpp
@@ -948,10 +948,6 @@ void die(const char * const error)
        exit(EXIT_FAILURE);
 }
 
-static struct gui_clipboard_table beos_clipboard_table = {
-       gui_get_clipboard,
-       gui_set_clipboard,
-};
 
 static struct gui_fetch_table beos_fetch_table = {
        fetch_filetype,
@@ -981,7 +977,7 @@ int main(int argc, char** argv)
                &beos_misc_table,
                beos_window_table,
                beos_download_table,
-               &beos_clipboard_table,
+               beos_clipboard_table,
                 &beos_fetch_table,
                 NULL, /* use POSIX file */
                 NULL, /* default utf8 */
diff --git a/beos/window.cpp b/beos/window.cpp
index ed6abcb..89fb781 100644
--- a/beos/window.cpp
+++ b/beos/window.cpp
@@ -407,7 +407,7 @@ static struct gui_window *gui_window_create(struct 
browser_window *bw,
        return g;
 }
 
-
+/* exported interface documented in beos/window.h */
 void nsbeos_dispatch_event(BMessage *message)
 {
        struct gui_window *gui = NULL;
@@ -1266,7 +1266,7 @@ static void gui_start_selection(struct gui_window *g)
        g->view->UnlockLooper();
 }
 
-void gui_get_clipboard(char **buffer, size_t *length)
+static void gui_get_clipboard(char **buffer, size_t *length)
 {
        BMessage *clip;
        *length = 0;
@@ -1288,7 +1288,7 @@ void gui_get_clipboard(char **buffer, size_t *length)
        }
 }
 
-void gui_set_clipboard(const char *buffer, size_t length,
+static void gui_set_clipboard(const char *buffer, size_t length,
        nsclipboard_styles styles[], int n_styles)
 {
        BMessage *clip;
@@ -1320,6 +1320,13 @@ void gui_set_clipboard(const char *buffer, size_t length,
        }
 }
 
+static struct gui_clipboard_table clipboard_table = {
+       gui_get_clipboard,
+       gui_set_clipboard,
+};
+
+struct gui_clipboard_table *beos_clipboard_table = &clipboard_table;
+
 static void gui_window_get_dimensions(struct gui_window *g, int *width, int 
*height,
                               bool scaled)
 {
diff --git a/beos/window.h b/beos/window.h
index 0aec92f..e00b379 100644
--- a/beos/window.h
+++ b/beos/window.h
@@ -19,49 +19,61 @@
 #ifndef NETSURF_BEOS_WINDOW_H
 #define NETSURF_BEOS_WINDOW_H 1
 
-extern "C" {
-#include "content/content.h"
-#include "desktop/browser.h"
-}
-#include "beos/scaffolding.h"
-
 extern struct gui_window_table *beos_window_table;
+extern struct gui_clipboard_table *beos_clipboard_table;
+
+struct gui_window;
+struct browser_window;
+struct beos_scaffolding;
 
 class NSBrowserFrameView : public BView {
 public:
-               NSBrowserFrameView(BRect frame, struct gui_window *gui);
-virtual        ~NSBrowserFrameView();
+       NSBrowserFrameView(BRect frame, struct gui_window *gui);
+       virtual ~NSBrowserFrameView();
 
-virtual void   MessageReceived(BMessage *message);
-virtual void   Draw(BRect updateRect);
+       virtual void MessageReceived(BMessage *message);
+       virtual void Draw(BRect updateRect);
 
-//virtual void FrameMoved(BPoint new_location);
-virtual void   FrameResized(float new_width, float new_height);
+        //virtual void FrameMoved(BPoint new_location);
+       virtual void FrameResized(float new_width, float new_height);
 
-virtual void   KeyDown(const char *bytes, int32 numBytes);
-virtual void   MouseDown(BPoint where);
-virtual void   MouseUp(BPoint where);
-virtual void   MouseMoved(BPoint where, uint32 transit, const BMessage *msg);
+       virtual void KeyDown(const char *bytes, int32 numBytes);
+       virtual void MouseDown(BPoint where);
+       virtual void MouseUp(BPoint where);
+       virtual void MouseMoved(BPoint where, uint32 transit, const BMessage 
*msg);
 
 private:
        struct gui_window *fGuiWindow;
 };
 
+/**
+ * Process beos messages into browser operations.
+ *
+ * \param message The beos message to process.
+ */
 void nsbeos_dispatch_event(BMessage *message);
 
-
+/**
+ * Cause all windows to be reflowed.
+ */
 void nsbeos_reflow_all_windows(void);
 
-nsbeos_scaffolding *nsbeos_get_scaffold(struct gui_window *g);
+/**
+ * Get containing scaffold of a beos gui window
+ *
+ * \param g gui window to find scaffold of.
+ * \return The containing scaffold.
+ */
+struct beos_scaffolding *nsbeos_get_scaffold(struct gui_window *g);
+
 struct browser_window *nsbeos_get_browser_for_gui(struct gui_window *g);
 
 float nsbeos_get_scale_for_gui(struct gui_window *g);
+
 int nsbeos_gui_window_update_targets(struct gui_window *g);
+
 void nsbeos_window_destroy_browser(struct gui_window *g);
 
 struct browser_window *nsbeos_get_browser_window(struct gui_window *g);
 
-void gui_get_clipboard(char **buffer, size_t *length);
-void gui_set_clipboard(const char *buffer, size_t length, nsclipboard_styles 
styles[], int n_styles);
-
 #endif /* NETSURF_BEOS_WINDOW_H */


-----------------------------------------------------------------------

Summary of changes:
 beos/gui.cpp    |    6 +-----
 beos/window.cpp |   13 ++++++++++---
 beos/window.h   |   54 +++++++++++++++++++++++++++++++++---------------------
 3 files changed, 44 insertions(+), 29 deletions(-)

diff --git a/beos/gui.cpp b/beos/gui.cpp
index 4fd2ecf..95b1597 100644
--- a/beos/gui.cpp
+++ b/beos/gui.cpp
@@ -948,10 +948,6 @@ void die(const char * const error)
        exit(EXIT_FAILURE);
 }
 
-static struct gui_clipboard_table beos_clipboard_table = {
-       gui_get_clipboard,
-       gui_set_clipboard,
-};
 
 static struct gui_fetch_table beos_fetch_table = {
        fetch_filetype,
@@ -981,7 +977,7 @@ int main(int argc, char** argv)
                &beos_misc_table,
                beos_window_table,
                beos_download_table,
-               &beos_clipboard_table,
+               beos_clipboard_table,
                 &beos_fetch_table,
                 NULL, /* use POSIX file */
                 NULL, /* default utf8 */
diff --git a/beos/window.cpp b/beos/window.cpp
index ed6abcb..89fb781 100644
--- a/beos/window.cpp
+++ b/beos/window.cpp
@@ -407,7 +407,7 @@ static struct gui_window *gui_window_create(struct 
browser_window *bw,
        return g;
 }
 
-
+/* exported interface documented in beos/window.h */
 void nsbeos_dispatch_event(BMessage *message)
 {
        struct gui_window *gui = NULL;
@@ -1266,7 +1266,7 @@ static void gui_start_selection(struct gui_window *g)
        g->view->UnlockLooper();
 }
 
-void gui_get_clipboard(char **buffer, size_t *length)
+static void gui_get_clipboard(char **buffer, size_t *length)
 {
        BMessage *clip;
        *length = 0;
@@ -1288,7 +1288,7 @@ void gui_get_clipboard(char **buffer, size_t *length)
        }
 }
 
-void gui_set_clipboard(const char *buffer, size_t length,
+static void gui_set_clipboard(const char *buffer, size_t length,
        nsclipboard_styles styles[], int n_styles)
 {
        BMessage *clip;
@@ -1320,6 +1320,13 @@ void gui_set_clipboard(const char *buffer, size_t length,
        }
 }
 
+static struct gui_clipboard_table clipboard_table = {
+       gui_get_clipboard,
+       gui_set_clipboard,
+};
+
+struct gui_clipboard_table *beos_clipboard_table = &clipboard_table;
+
 static void gui_window_get_dimensions(struct gui_window *g, int *width, int 
*height,
                               bool scaled)
 {
diff --git a/beos/window.h b/beos/window.h
index 0aec92f..e00b379 100644
--- a/beos/window.h
+++ b/beos/window.h
@@ -19,49 +19,61 @@
 #ifndef NETSURF_BEOS_WINDOW_H
 #define NETSURF_BEOS_WINDOW_H 1
 
-extern "C" {
-#include "content/content.h"
-#include "desktop/browser.h"
-}
-#include "beos/scaffolding.h"
-
 extern struct gui_window_table *beos_window_table;
+extern struct gui_clipboard_table *beos_clipboard_table;
+
+struct gui_window;
+struct browser_window;
+struct beos_scaffolding;
 
 class NSBrowserFrameView : public BView {
 public:
-               NSBrowserFrameView(BRect frame, struct gui_window *gui);
-virtual        ~NSBrowserFrameView();
+       NSBrowserFrameView(BRect frame, struct gui_window *gui);
+       virtual ~NSBrowserFrameView();
 
-virtual void   MessageReceived(BMessage *message);
-virtual void   Draw(BRect updateRect);
+       virtual void MessageReceived(BMessage *message);
+       virtual void Draw(BRect updateRect);
 
-//virtual void FrameMoved(BPoint new_location);
-virtual void   FrameResized(float new_width, float new_height);
+        //virtual void FrameMoved(BPoint new_location);
+       virtual void FrameResized(float new_width, float new_height);
 
-virtual void   KeyDown(const char *bytes, int32 numBytes);
-virtual void   MouseDown(BPoint where);
-virtual void   MouseUp(BPoint where);
-virtual void   MouseMoved(BPoint where, uint32 transit, const BMessage *msg);
+       virtual void KeyDown(const char *bytes, int32 numBytes);
+       virtual void MouseDown(BPoint where);
+       virtual void MouseUp(BPoint where);
+       virtual void MouseMoved(BPoint where, uint32 transit, const BMessage 
*msg);
 
 private:
        struct gui_window *fGuiWindow;
 };
 
+/**
+ * Process beos messages into browser operations.
+ *
+ * \param message The beos message to process.
+ */
 void nsbeos_dispatch_event(BMessage *message);
 
-
+/**
+ * Cause all windows to be reflowed.
+ */
 void nsbeos_reflow_all_windows(void);
 
-nsbeos_scaffolding *nsbeos_get_scaffold(struct gui_window *g);
+/**
+ * Get containing scaffold of a beos gui window
+ *
+ * \param g gui window to find scaffold of.
+ * \return The containing scaffold.
+ */
+struct beos_scaffolding *nsbeos_get_scaffold(struct gui_window *g);
+
 struct browser_window *nsbeos_get_browser_for_gui(struct gui_window *g);
 
 float nsbeos_get_scale_for_gui(struct gui_window *g);
+
 int nsbeos_gui_window_update_targets(struct gui_window *g);
+
 void nsbeos_window_destroy_browser(struct gui_window *g);
 
 struct browser_window *nsbeos_get_browser_window(struct gui_window *g);
 
-void gui_get_clipboard(char **buffer, size_t *length);
-void gui_set_clipboard(const char *buffer, size_t length, nsclipboard_styles 
styles[], int n_styles);
-
 #endif /* NETSURF_BEOS_WINDOW_H */


-- 
NetSurf Browser

_______________________________________________
netsurf-commits mailing list
[email protected]
http://listmaster.pepperfish.net/cgi-bin/mailman/listinfo/netsurf-commits-netsurf-browser.org

Reply via email to