]> git.saurik.com Git - wxWidgets.git/commitdiff
wxFileIn/OutputStream fix
authorGuilhem Lavaux <lavaux@easynet.fr>
Mon, 24 May 1999 12:05:30 +0000 (12:05 +0000)
committerGuilhem Lavaux <lavaux@easynet.fr>
Mon, 24 May 1999 12:05:30 +0000 (12:05 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@2549 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/common/wfstream.cpp

index 4d798f3c7913893d4a0fe36ef3f03ab0279a8abb..885bab4cf975ac8c1fdac0d6e06861e847e290d6 100644 (file)
@@ -42,6 +42,20 @@ wxFileInputStream::wxFileInputStream()
   m_file = NULL;
 }
 
+wxFileInputStream::wxFileInputStream(wxFile& file)
+{
+  m_file = &file;
+  m_file_destroy = FALSE;
+  m_i_streambuf->SetBufferIO(1024);
+}
+
+wxFileInputStream::wxFileInputStream(int fd)
+{
+  m_file = new wxFile(fd);
+  m_file_destroy = TRUE;
+  m_i_streambuf->SetBufferIO(1024);
+}
+
 wxFileInputStream::~wxFileInputStream()
 {
   if (m_file_destroy)
@@ -99,6 +113,13 @@ wxFileOutputStream::wxFileOutputStream()
   m_file = NULL;
 }
 
+wxFileOutputStream::wxFileOutputStream(int fd)
+{
+  m_file = new wxFile(fd);
+  m_file_destroy = TRUE;
+  m_o_streambuf->SetBufferIO(1024);
+}
+
 wxFileOutputStream::~wxFileOutputStream()
 {
   if (m_file_destroy) {