[Libreoffice-commits] core.git: cui/source include/tools sc/source sc/uiconfig svtools/source svx/source sw/source tools/source vcl/source

2017-09-28 Thread Stephan Bergmann
 cui/source/dialogs/about.cxx|2 
 include/tools/stream.hxx|   28 -
 sc/source/filter/excel/xestyle.cxx  |1 
 sc/source/ui/docshell/datastream.cxx|6 --
 sc/source/ui/inc/datastream.hxx |2 
 sc/source/ui/inc/datastreamdlg.hxx  |2 
 sc/source/ui/miscdlgs/datastreamdlg.cxx |9 
 sc/uiconfig/scalc/ui/datastreams.ui |   46 --
 svtools/source/svhtml/parhtml.cxx   |2 
 svx/source/svdraw/svdmark.cxx   |2 
 sw/source/filter/ww8/rtfattributeoutput.cxx |1 
 tools/source/stream/stream.cxx  |   57 
 vcl/source/outdev/text.cxx  |2 
 13 files changed, 9 insertions(+), 151 deletions(-)

New commits:
commit 9e0be8a76e13ed3d71e792c1a30e5628b7e1056e
Author: Stephan Bergmann 
Date:   Thu Sep 28 18:35:50 2017 +0200

Remove dead code behind Calc "Live Data Streams" dialog's "scriptdata" 
button

...that has been disabled and hidden ever since
4c90ed782a09e2e4b8738b82028032c42d1a203d "Actually hide these two radio 
buttons
(since there is no choice now)."

This removes the sole user of SvScriptStream.  (Unfortunately, removing the 
no
longer needed

  #include 

from include/tools/stream.hxx triggered an avalanche of missing includes
elsewhere.)

Change-Id: I7b0e683b14c0eaf7f4737f62adc9d691826380c0
Reviewed-on: https://gerrit.libreoffice.org/42916
Reviewed-by: Michael Meeks 
Tested-by: Michael Meeks 

diff --git a/cui/source/dialogs/about.cxx b/cui/source/dialogs/about.cxx
index 6a4baa7ce75b..ea46ac3f8807 100644
--- a/cui/source/dialogs/about.cxx
+++ b/cui/source/dialogs/about.cxx
@@ -18,7 +18,7 @@
  */
 
 #include 
-
+#include 
 #include 
 #include 
 #include 
diff --git a/include/tools/stream.hxx b/include/tools/stream.hxx
index 0a4164e8dfa6..b4d1be9517bf 100644
--- a/include/tools/stream.hxx
+++ b/include/tools/stream.hxx
@@ -20,7 +20,6 @@
 #define INCLUDED_TOOLS_STREAM_HXX
 
 #include 
-#include 
 #include 
 #include 
 #include 
@@ -678,33 +677,6 @@ public:
 virtual sal_uInt64 remainingSize() override { FlushBuffer(true); return 
GetEndOfData() - Tell(); }
 };
 
-class TOOLS_DLLPUBLIC SvScriptStream: public SvStream
-{
-oslProcess mpProcess;
-oslFileHandle mpHandle;
-
-public:
-SvScriptStream(const OUString& rUrl);
-virtual ~SvScriptStream() override;
-
-/** Read a line of bytes.
-
-@param nMaxBytesToRead
-   Maximum of bytes to read, if line is longer it will be
-   truncated.
-
-@note NOTE that the default is one character less than STRING_MAXLEN to
-  prevent problems after conversion to String that may be lurking
-  in various places doing something like
-  @code
-for (sal_uInt16 i=0; i < aString.Len(); ++i)
-  @endcode
-  causing endless loops ...
-*/
-virtual bool ReadLine(OString& rStr, sal_Int32 nMaxBytesToRead = 0xFFFE ) 
override;
-virtual bool good() const override;
-};
-
 #endif
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/source/filter/excel/xestyle.cxx 
b/sc/source/filter/excel/xestyle.cxx
index d907ccbcb29f..d627ebd0500f 100644
--- a/sc/source/filter/excel/xestyle.cxx
+++ b/sc/source/filter/excel/xestyle.cxx
@@ -25,6 +25,7 @@
 #include 
 #include 
 #include 
+#include 
 #include 
 #include 
 #include 
diff --git a/sc/source/ui/docshell/datastream.cxx 
b/sc/source/ui/docshell/datastream.cxx
index a153726e06a2..f99384142ed0 100644
--- a/sc/source/ui/docshell/datastream.cxx
+++ b/sc/source/ui/docshell/datastream.cxx
@@ -401,11 +401,7 @@ void DataStream::StartImport()
 
 if (!mxReaderThread.is())
 {
-SvStream *pStream = nullptr;
-if (mnSettings & SCRIPT_STREAM)
-pStream = new SvScriptStream(msURL);
-else
-pStream = new SvFileStream(msURL, StreamMode::READ);
+SvStream *pStream = new SvFileStream(msURL, StreamMode::READ);
 mxReaderThread = new datastreams::ReaderThread(pStream, 
maStartRange.aEnd.Col() - maStartRange.aStart.Col() + 1);
 mxReaderThread->launch();
 }
diff --git a/sc/source/ui/inc/datastream.hxx b/sc/source/ui/inc/datastream.hxx
index e70b5e47626e..b60de3fb852e 100644
--- a/sc/source/ui/inc/datastream.hxx
+++ b/sc/source/ui/inc/datastream.hxx
@@ -66,7 +66,7 @@ public:
 typedef std::vector LinesType;
 
 enum MoveType { NO_MOVE, RANGE_DOWN, MOVE_DOWN, MOVE_UP };
-enum { SCRIPT_STREAM = 1, VALUES_IN_LINE = 2 };
+enum { VALUES_IN_LINE = 2 };
 
 static void MakeToolbarVisible();
 static DataStream* Set(ScDocShell *pShell, const OUString& rURL, const 
ScRange& rRange,
diff --git a/sc/source/ui/inc/datastreamdlg.hxx 

[Libreoffice-commits] core.git: cui/source include/tools sfx2/source svx/source tools/source

2015-04-02 Thread Tor Lillqvist
 cui/source/dialogs/cuihyperdlg.cxx |2 
 include/tools/urlobj.hxx   |3 
 sfx2/source/doc/docfile.cxx|2 
 svx/source/form/fmpage.cxx |2 
 tools/source/fsys/urlobj.cxx   |  217 +
 5 files changed, 81 insertions(+), 145 deletions(-)

New commits:
commit 5241788281e315fc735e5322b3b642486be52c50
Author: Tor Lillqvist t...@collabora.com
Date:   Wed Apr 1 15:05:30 2015 +0300

Kill INetProtocol::Imap and Pop3

I doubt very much these actually get used. Couldn't find in any of the 
sample
bug docs collected from bugzillas, for instance.

Change-Id: I47a586fabb1efdf8315ed5f7bd09cbaea4c860b5

diff --git a/cui/source/dialogs/cuihyperdlg.cxx 
b/cui/source/dialogs/cuihyperdlg.cxx
index 8c48d51..5043af6 100644
--- a/cui/source/dialogs/cuihyperdlg.cxx
+++ b/cui/source/dialogs/cuihyperdlg.cxx
@@ -310,8 +310,6 @@ sal_uInt16 SvxHpLinkDlg::SetPage ( SvxHyperlinkItem* pItem )
 nPageId = RID_SVXPAGE_HYPERLINK_INTERNET;
 break;
 case INetProtocol::File :
-case INetProtocol::Pop3 :
-case INetProtocol::Imap :
 nPageId = RID_SVXPAGE_HYPERLINK_DOCUMENT;
 break;
 case INetProtocol::Mailto :
diff --git a/include/tools/urlobj.hxx b/include/tools/urlobj.hxx
index fd7dc2d..23978fe 100644
--- a/include/tools/urlobj.hxx
+++ b/include/tools/urlobj.hxx
@@ -79,8 +79,6 @@ enum class INetProtocol
 Slot,
 Macro,
 Javascript,
-Imap,
-Pop3,
 Data,
 Cid,
 Out,
@@ -868,7 +866,6 @@ public:
 enum Part
 {
 PART_USER_PASSWORD  = 0x1,
-PART_IMAP_ACHAR = 0x2,
 PART_VIM= 0x4,
 PART_FPATH  = 0x8,
 PART_AUTHORITY  = 0x00010,
diff --git a/sfx2/source/doc/docfile.cxx b/sfx2/source/doc/docfile.cxx
index e0158ae..db0f0e9 100644
--- a/sfx2/source/doc/docfile.cxx
+++ b/sfx2/source/doc/docfile.cxx
@@ -2683,9 +2683,7 @@ void SfxMedium::SetIsRemote_Impl()
 case INetProtocol::Ftp:
 case INetProtocol::Http:
 case INetProtocol::Https:
-case INetProtocol::Pop3:
 case INetProtocol::News:
-case INetProtocol::Imap:
 case INetProtocol::Vim:
 pImp-m_bRemote = true;
 break;
diff --git a/svx/source/form/fmpage.cxx b/svx/source/form/fmpage.cxx
index b0c080a..b27cdc1 100644
--- a/svx/source/form/fmpage.cxx
+++ b/svx/source/form/fmpage.cxx
@@ -192,7 +192,7 @@ bool FmFormPage::RequestHelp( vcl::Window* pWindow, 
SdrView* pView,
 INetProtocol aProtocol = aUrl.GetProtocol();
 static const INetProtocol s_aQuickHelpSupported[] =
 {   INetProtocol::Ftp, INetProtocol::Http, INetProtocol::File, 
INetProtocol::Mailto, INetProtocol::News,
-INetProtocol::Https, INetProtocol::Javascript, 
INetProtocol::Imap, INetProtocol::Pop3,
+INetProtocol::Https, INetProtocol::Javascript,
 INetProtocol::Vim, INetProtocol::Ldap
 };
 for (sal_uInt16 i=0; 
isizeof(s_aQuickHelpSupported)/sizeof(s_aQuickHelpSupported[0]); ++i)
diff --git a/tools/source/fsys/urlobj.cxx b/tools/source/fsys/urlobj.cxx
index 1744d27..478a55b 100644
--- a/tools/source/fsys/urlobj.cxx
+++ b/tools/source/fsys/urlobj.cxx
@@ -152,18 +152,6 @@ using namespace css;
javascript-url = JAVASCRIPT: *uric
 
 
-   ; private (see RFC 2192)
-   imap-url = IMAP:// user [;AUTH= auth] @ hostport / segment *(/ 
segment) [/;UID= nz_number]
-   user = 1*{RFC 2060 CHAR8 using (escaped / alphanum / ! / $ /  / 
' / ( / ) / * / + / , / - / . / = / _ / ~)}
-   auth = {RFC 2060 atom using *(escaped / alphanum / ! / $ /  / ' 
/ + / , / - / . / = / _ / ~)}
-   segment = *(escaped / alphanum / ! / $ /  / ' / ( / ) / * / 
+ / , / - / . / : / = / @ / _ / ~)
-   nz_number = {RFC 2060 nz_number using *DIGIT}
-
-
-   ; private
-   pop3-url = POP3:// login [/ [ *uric ]]
-
-
; RFC 2397
data-url = DATA: [mediatype] [;BASE64] , *uric
mediatype = [type / subtype] *(; attribute = value)
@@ -385,12 +373,6 @@ INetURLObject::getSchemeInfo(INetProtocol eTheScheme)
 javascript, javascript:, 0, false, false, false, false, false,
 false, false, false},
 SchemeInfo{
-imap, imap://, 143, true, true, true, false, true, true, true,
-false},
-SchemeInfo{
-pop3, pop3://, 110, true, true, false, true, true, true, false,
-false},
-SchemeInfo{
 data, data:, 0, false, false, false, false, false, false, 
false,
 false},
 SchemeInfo{
@@ -469,7 +451,6 @@ namespace unnamed_tools_urlobj {
 enum
 {
 PA = INetURLObject::PART_USER_PASSWORD,
-PB = INetURLObject::PART_IMAP_ACHAR,
 PC = INetURLObject::PART_VIM,
 PD = INetURLObject::PART_FPATH,
 PE = INetURLObject::PART_AUTHORITY,
@@ -493,100 

[Libreoffice-commits] core.git: cui/source include/tools

2014-07-10 Thread Noel Grandin
 cui/source/dialogs/linkdlg.cxx |2 +-
 include/tools/ref.hxx  |   21 +++--
 2 files changed, 8 insertions(+), 15 deletions(-)

New commits:
commit 5a3d129a46a9f749439eeaff473ffb848a9650cf
Author: Noel Grandin n...@peralex.com
Date:   Thu Jul 10 11:03:27 2014 +0200

remove SvRefBase::ReleaseReference

because no-one is using the return value of ReleaseRef, but everyone is
calling ReleaseRef, so make ReleaseRef void-returning and remove
ReleaseReference

Change-Id: I0bedcb65a887ba7a4953132b4c1ccefbdd554a43

diff --git a/cui/source/dialogs/linkdlg.cxx b/cui/source/dialogs/linkdlg.cxx
index 9155325..27abd85 100644
--- a/cui/source/dialogs/linkdlg.cxx
+++ b/cui/source/dialogs/linkdlg.cxx
@@ -60,7 +60,7 @@ public:
 {
 SvBaseLink* p = *it;
 if( p )
-p-ReleaseReference();
+p-ReleaseRef();
 }
 }
 
diff --git a/include/tools/ref.hxx b/include/tools/ref.hxx
index 87aed32..a87d099 100644
--- a/include/tools/ref.hxx
+++ b/include/tools/ref.hxx
@@ -37,13 +37,13 @@ public:
 
 SvRef(T * pObjP): pObj(pObjP) { if (pObj != 0) pObj-AddRef(); }
 
-~SvRef() { if (pObj != 0) pObj-ReleaseReference(); }
+~SvRef() { if (pObj != 0) pObj-ReleaseRef(); }
 
 void Clear() {
 if (pObj != 0) {
 T * pRefObj = pObj;
 pObj = 0;
-pRefObj-ReleaseReference();
+pRefObj-ReleaseRef();
 }
 }
 
@@ -54,7 +54,7 @@ public:
 T * pRefObj = pObj;
 pObj = rObj.pObj;
 if (pRefObj != 0) {
-pRefObj-ReleaseReference();
+pRefObj-ReleaseRef();
 }
 return *this;
 }
@@ -102,7 +102,7 @@ public:
 {
   T p = *it;
   if( p )
-  p-ReleaseReference();
+  p-ReleaseRef();
 }
 base_t::clear();
 }
@@ -126,7 +126,7 @@ public:
 T p = base_t::back();
 base_t::pop_back();
 if( p )
-p-ReleaseReference();
+p-ReleaseRef();
 return p;
 }
 };
@@ -159,18 +159,11 @@ public:
 nRefCount -= SV_NO_DELETE_REFCOUNT;
 return ++nRefCount;
 }
-voidReleaseReference()
+voidReleaseRef()
 {
 if( !--nRefCount )
 QueryDelete();
 }
-sal_uIntPtr ReleaseRef()
-{
-sal_uIntPtr n = --nRefCount;
-if( !n )
-QueryDelete();
-return n;
-}
 sal_uIntPtr GetRefCount() const { return nRefCount; }
 };
 
@@ -196,7 +189,7 @@ class SvCompatWeakBase
 public:
 SvCompatWeakHdl* GetHdl() { return _xHdl; }
 
-// does not use Initalizer due to compiler warnings
+// does not use initalizer due to compiler warnings
 SvCompatWeakBase( void* pObj ) { _xHdl = new SvCompatWeakHdl( pObj ); }
 ~SvCompatWeakBase() { _xHdl-ResetWeakBase(); }
 };
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits