From cdea9154ff180e95dfbdd8e0647922ca8afa3d46 Mon Sep 17 00:00:00 2001 From: Kelly Rauchenberger Date: Sat, 21 May 2016 11:30:28 -0400 Subject: Projects using libtwitter++ no longer have to include its dependencies --- src/client.cpp | 4 +++- src/client.h | 12 +++++------- 2 files changed, 8 insertions(+), 8 deletions(-) (limited to 'src') diff --git a/src/client.cpp b/src/client.cpp index ffb651b..bae563f 100644 --- a/src/client.cpp +++ b/src/client.cpp @@ -3,6 +3,8 @@ #include #include #include +#include +#include #include "util.h" #include @@ -727,7 +729,7 @@ namespace twitter { } } - int client::stream::write(char* ptr, size_t size, size_t nmemb) + size_t client::stream::write(char* ptr, size_t size, size_t nmemb) { for (size_t i = 0; i < size*nmemb; i++) { diff --git a/src/client.h b/src/client.h index ae80ed9..750d603 100644 --- a/src/client.h +++ b/src/client.h @@ -5,8 +5,6 @@ #include "tweet.h" #include "auth.h" #include -#include -#include #include #include #include "notification.h" @@ -20,6 +18,8 @@ namespace OAuth { class Client; }; +class curl_httppost; + namespace twitter { class client { @@ -36,6 +36,9 @@ namespace twitter { void start(); void stop(); + int progress(); + size_t write(char* ptr, size_t size, size_t nmemb); + private: enum class backoff { none, @@ -45,11 +48,6 @@ namespace twitter { }; void run(); - int progress(); - int write(char* ptr, size_t size, size_t nmemb); - - friend int client_stream_progress_callback_wrapper(void* stream, curl_off_t, curl_off_t, curl_off_t, curl_off_t); - friend size_t client_stream_write_callback_wrapper(void* ptr, size_t size, size_t nmemb, void* stream); client& _client; notify_callback _notify; -- cgit 1.4.1