Commit Graph

1267 Commits

Author SHA1 Message Date
Stephan Bergmann
e46e8d1945 Shall this produce a string representation of a number?
On the one hand, the code had apparently treated nIdx as a sal_Unicode character
value ever since its inception in e718950884 "new
querydesign."  On the other hand, the preceding BROW_VIS_ROW case does produce
strings "0" and "1".

Change-Id: Ife6e98ba32146cc469b722fa4f013c12152b5505
2015-06-19 11:04:14 +02:00
Andrea Gelmini
9b7e1bf43d Fix typos
Change-Id: Ieaf67cf597e05dbae5affa153af907fda4462a41
Reviewed-on: https://gerrit.libreoffice.org/16295
Reviewed-by: Michael Stahl <mstahl@redhat.com>
Tested-by: Michael Stahl <mstahl@redhat.com>
2015-06-16 10:59:53 +00:00
Noel Grandin
4ea281a3cc cppcheck:redundantAssignment
Change-Id: I1167d0ce6b6f6e48309d0551c1d2a283d79546a7
2015-06-15 13:34:14 +02:00
Andrea Gelmini
c3c45ff7ef Fix typos
Change-Id: Id05ea8cf8aed878bedfe73c274df3c67b64bad37
Reviewed-on: https://gerrit.libreoffice.org/16263
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2015-06-15 06:53:19 +00:00
Stephan Bergmann
8538026000 loplugin:cstylecast: deal with remaining pointer casts
Change-Id: If951c1982314c5a045d51bc4fff62a3e2b265e08
2015-06-08 16:24:31 +02:00
Noel Grandin
3f72218069 Apply new VclPtr clang plugin to catch potential problems.
Omit the plugin, and sw's FrameControlsManager for now.

Change-Id: Ifb98a2e6e03a9d099efc1668305b96bd9142ca5f
Reviewed-on: https://gerrit.libreoffice.org/16117
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2015-06-06 20:26:54 +00:00
Michael Meeks
ba81e5c6bd tdf#91702 - fix stack-based MessBox allocation.
Change-Id: I62dd164e281911d9db3de453789a5badc7cd5fd7
Reviewed-on: https://gerrit.libreoffice.org/15954
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2015-05-29 12:16:28 +00:00
Noel Grandin
49ea2258d4 loplugin:loopvartoosmall
Change-Id: I5518e40a30bdad53470cc52b59eff04ab6d873d4
2015-05-29 08:48:41 +02:00
Noel Grandin
abb7747222 simplify
Change-Id: I74288b1a29a928d14a022f39b63bbdab1517c68a
2015-05-29 08:48:09 +02:00
Caolán McNamara
2ecf0ced9d VclPtr: assert with query dialog open on closing query design
Change-Id: I40d196462ff2e37d86ca367d3a150c94872715f1
2015-05-28 15:21:03 +01:00
Caolán McNamara
82f15336cf VclPtr: undisposed things and dispose order on query design window close
Change-Id: I3070d52e15febe2f5981ffdf5d665e28fa4f799b
2015-05-28 15:07:43 +01:00
Philippe Jung
1379e2feaa Rewrite all calls like Dialog(params).Execute()
Replace all calls looking like
  ADialog(some params).Execute()
by
  ScopedVclPtrInstance<ADialog>::Create(some parms)->Execute()

Change-Id: I0b6f0a9ea5ef0a749ffa30ce131e9dc989604639
Reviewed-on: https://gerrit.libreoffice.org/15915
Tested-by: Jenkins <ci@libreoffice.org>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2015-05-28 08:44:31 +00:00
Noel Grandin
bb7ce3137d convert INVALIDATE constants to scoped enum
fixing a bug in Window::ImplMoveAllInvalidateRegions, and improving the
IDL docs for XWindowPeer

Change-Id: Idb774ac913945db2ac7c492c11cf86c370624c3d
2015-05-26 08:30:18 +02:00
Michael Meeks
e4097762dd Audit all PostUserEvent calls and instrument for VclPtr.
Hold a reference on the VclPtr while we're waiting for the UserEvent.

Change-Id: I55c2671ca12eb14761c6a7dffd551af71547ecbd
2015-05-25 21:38:08 +01:00
Noel Grandin
65be8fd0f7 convert WINDOW_ZORDER constants to scoped enum
Change-Id: I91a583fe7d4195ee6bc73b4854f757517b38408b
2015-05-25 10:31:35 +02:00
Noel Grandin
e929194317 convert POINTER constants to scoped enum
Change-Id: Iea29ce5fd6c620535197d3ca8538335078430e19
Reviewed-on: https://gerrit.libreoffice.org/15825
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
2015-05-22 06:32:35 +00:00
Noel Grandin
23b439a664 convert DEFAULTCONSTANT constant to scoped enum
Change-Id: I5ebd77edfa29d6c6c7acea37e826ef1d625916c3
2015-05-20 09:52:09 +02:00
Noel Grandin
25a47c5cd5 convert TEXT_DRAW constants to scoped enum
Change-Id: Ic0f7f8fa236bb478b3598ae3fd3c1b30ebbf1a01
2015-05-20 09:52:08 +02:00
Tomaž Vajngerl
b4bbb5e5d7 refactor how font, fg. and bg. are applied in widgets/controls
- Move vcl::RenderContext to outdev.
- Change some methods on vcl::Window to accept RenderContext
  as parameter.
- Add ApplySettings to vcl::Window - This method is called before
  painting. Refactor existing classes that use InitSettings to
  have ApplySettings or mark the classes to be refactored later.
- Add RenderSettings for adding defered settings to rendering.
  This is similar to ApplySettings but for more ad-hoc calls.

Change-Id: I4ea58461f3b6b08ccfa3e0ddd1a4a3e04f8c4f45
2015-05-18 11:22:49 +09:00
Stephan Bergmann
c73a911942 loplugin:staticmethods
Change-Id: Id3a8fee18a954a14b63fd922803f8a7f13b49727
2015-05-17 22:02:06 +02:00
Tomaž Vajngerl
264fb9f163 refactor dbacess classes to use RenderContext
Change-Id: I60e436ec1e6974e5fb8c6525552c6e172ceca0ca
2015-05-16 21:57:15 +09:00
Noel Grandin
82d68f9cbc convert COMMAND_ constants to scoped enum
Change-Id: I88e67f89dbbab0646e8f106dfeb32c6ee1bb0b95
Reviewed-on: https://gerrit.libreoffice.org/15671
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2015-05-11 12:17:42 +00:00
Stephan Bergmann
6dc42c82ba Use IMPL_LINK_NOARG[_TYPED] where applicable
Change-Id: I70598072c1d492e360ef46dd7b5ef5a2fa4be495
2015-05-10 12:06:16 +02:00
Michael Meeks
266ce1cd53 tdf#91052 - more macros for 'make' constructors.
Change-Id: Id05266810760f73db2daba10d1efa14aa9f88dd9
2015-05-09 21:39:57 +01:00
Takeshi Abe
7d8b03256e dbaccess: simplify code by using std::any_of/std::none_of
Change-Id: I03ed512ba20206ed38428efe324f54f79abe1933
Reviewed-on: https://gerrit.libreoffice.org/15616
Tested-by: Jenkins <ci@libreoffice.org>
Tested-by: David Tardon <dtardon@redhat.com>
Reviewed-by: David Tardon <dtardon@redhat.com>
2015-05-06 14:41:26 +00:00
Noel Grandin
bfcb2a1a75 convert DEFAULTFONT_ constants to scoped enum
Change-Id: Ia33e957f6cf530e2639b3c86d9482f642652cb46
2015-05-06 09:01:29 +02:00
Michael Stahl
8fca0c44e8 vcl: rename other members of StateChangedType for consistency
Change-Id: Ifd3339813e5d3dfb54566fd226aaf2d2a199d59a
2015-05-05 15:51:11 +02:00
Stephan Bergmann
c9b4c56811 Use typed Idle::SetIdleHdl Link
Change-Id: I189937950325dc4ef663f7f49cb45f38f8537de9
2015-05-05 12:05:38 +02:00
Stephan Bergmann
8cafd08278 Use typed Timer::SetTimeoutHdl Link
Change-Id: Iaaf0c93e5b28c0f7dbe4f02eda8beeae30708100
2015-05-05 10:21:54 +02:00
Noel Grandin
add1351e59 loplugin:staticmethods
Change-Id: Ie6867e04156f40cacee275d5bbf3d63ac4965b30
2015-05-05 09:30:39 +02:00
Caolán McNamara
47687ccb9d cppcheck: variableScope
Change-Id: Ice10ca4fdecfb446fa3f7680e89ea0d7dd2c1cb7
2015-05-03 09:34:13 +01:00
Michael Meeks
9d17e1250a Audit LoseFocus - basctl, cui, dbaccess.
Change-Id: If61b45f28f30e3ab00dbf071198233d59899d719
2015-05-02 00:49:58 +02:00
Tor Lillqvist
d1ca0f4ed0 Bin some pointless comments and reduce some vertical whitespace
Bin pointless '// predeclarations' or '// forward declarations' comments.  If
a programmer doesn't know what a forward declaration is, well, why read C++
source code?

Also bin some pointless '// end of namespace foo' comments after namespace
blocks just a handful of lines long, and some superfluous vertical whitespace.

Change-Id: I2a31c5d73d9b4de8825fb8eb9e7559dbd7303ef9
2015-04-30 06:14:12 +03:00
Tomaž Vajngerl
6cea2e61cf fix compile: delegate RenderContext parameter to super
Change-Id: I1c08e29c45d8334db52b129a957098481f3e57a4
2015-04-29 09:27:54 +09:00
Tomaž Vajngerl
f50fd9692e mass rewrite Paint(Rect&) to Paint(RenderContext&, Rect&)
Change-Id: Ia1667246064d11827dbd149def15e5bf08b119b8
2015-04-29 09:19:47 +09:00
Miklos Vajna
65a34bdc4d dbaccess: more GCC-4.7 fixes
Change-Id: Ia89a9984ce1d5230c1a57591b6bce87a5e22471a
2015-04-28 18:21:20 +02:00
Michael Meeks
e8b97a52c9 Merge remote-tracking branch 'origin/feature/vclptr'
Resolve several thousand lines of conflicts.

Conflicts:
	accessibility/source/extended/accessiblelistbox.cxx
	accessibility/source/standard/vclxaccessiblecombobox.cxx
	accessibility/source/standard/vclxaccessibledropdowncombobox.cxx
	accessibility/source/standard/vclxaccessibledropdownlistbox.cxx
	accessibility/source/standard/vclxaccessiblelistbox.cxx
	accessibility/source/standard/vclxaccessibletextfield.cxx
	basctl/source/basicide/basidesh.cxx
	cui/source/inc/chardlg.hxx
	cui/source/tabpages/tpbitmap.cxx
	dbaccess/source/ui/dlg/UserAdmin.cxx
	dbaccess/source/ui/querydesign/ConnectionLineAccess.cxx
	extensions/source/propctrlr/propertyeditor.hxx
	extensions/source/scanner/sanedlg.cxx
	filter/source/pdf/impdialog.cxx
	include/sfx2/mgetempl.hxx
	include/sfx2/sidebar/SidebarToolBox.hxx
	include/sfx2/viewsh.hxx
	include/svtools/brwbox.hxx
	include/svtools/filectrl.hxx
	include/svtools/scrwin.hxx
	include/svx/dlgctrl.hxx
	include/svx/sidebar/Popup.hxx
	include/svx/sidebar/PopupContainer.hxx
	include/svx/sidebar/PopupControl.hxx
	include/svx/sidebar/SidebarDialControl.hxx
	include/svx/sidebar/ValueSetWithTextControl.hxx
	sc/source/ui/condformat/condformatdlgentry.cxx
	sc/source/ui/navipi/navipi.cxx
	sc/source/ui/sidebar/CellBorderStyleControl.hxx
	sd/source/ui/animations/CustomAnimationDialog.cxx
	sd/source/ui/inc/DrawViewShell.hxx
	sd/source/ui/inc/Ruler.hxx
	sd/source/ui/inc/SlideSorter.hxx
	sd/source/ui/inc/ViewTabBar.hxx
	sd/source/ui/inc/Window.hxx
	sd/source/ui/inc/morphdlg.hxx
	sd/source/ui/inc/sdpreslt.hxx
	sd/source/ui/sidebar/CurrentMasterPagesSelector.hxx
	sd/source/ui/sidebar/LayoutMenu.hxx
	sd/source/ui/sidebar/MasterPagesSelector.hxx
	sd/source/ui/sidebar/NavigatorWrapper.hxx
	sd/source/ui/sidebar/PanelBase.hxx
	sd/source/ui/sidebar/RecentMasterPagesSelector.cxx
	sd/source/ui/sidebar/RecentMasterPagesSelector.hxx
	sd/source/ui/slideshow/showwindow.hxx
	sd/source/ui/slidesorter/view/SlsInsertAnimator.cxx
	sd/source/ui/slidesorter/view/SlsLayeredDevice.hxx
	sd/source/ui/view/ViewShellBase.cxx
	sd/source/ui/view/drviewsa.cxx
	sfx2/source/appl/fileobj.hxx
	sfx2/source/appl/opengrf.cxx
	sfx2/source/control/thumbnailviewacc.hxx
	sfx2/source/dialog/securitypage.cxx
	sfx2/source/dialog/templdlg.cxx
	sfx2/source/doc/docinsert.cxx
	sfx2/source/doc/guisaveas.cxx
	sfx2/source/inc/alienwarn.hxx
	sfx2/source/sidebar/Deck.cxx
	sfx2/source/sidebar/Deck.hxx
	sfx2/source/sidebar/DeckTitleBar.cxx
	sfx2/source/sidebar/DeckTitleBar.hxx
	sfx2/source/sidebar/MenuButton.cxx
	sfx2/source/sidebar/MenuButton.hxx
	sfx2/source/sidebar/Panel.cxx
	sfx2/source/sidebar/Panel.hxx
	sfx2/source/sidebar/PanelTitleBar.hxx
	sfx2/source/sidebar/SidebarDockingWindow.hxx
	sfx2/source/sidebar/SidebarToolBox.cxx
	sfx2/source/sidebar/TabBar.hxx
	sfx2/source/sidebar/TabItem.cxx
	sfx2/source/sidebar/TabItem.hxx
	sfx2/source/sidebar/TitleBar.hxx
	sfx2/source/toolbox/imgmgr.cxx
	starmath/inc/edit.hxx
	starmath/inc/smmod.hxx
	starmath/qa/cppunit/test_starmath.cxx
	starmath/source/edit.cxx
	starmath/source/smmod.cxx
	svtools/source/brwbox/brwbox1.cxx
	svtools/source/brwbox/datwin.hxx
	svtools/source/contnr/fileview.cxx
	svtools/source/contnr/simptabl.cxx
	svtools/source/control/filectrl.cxx
	svtools/source/control/valueimp.hxx
	svx/inc/GalleryControl.hxx
	svx/source/dialog/dlgctrl.cxx
	svx/source/dialog/swframeexample.cxx
	svx/source/fmcomp/fmgridif.cxx
	svx/source/gallery2/GalleryControl.cxx
	svx/source/sidebar/EmptyPanel.hxx
	svx/source/sidebar/area/AreaPropertyPanel.hxx
	svx/source/sidebar/area/AreaTransparencyGradientControl.hxx
	svx/source/sidebar/graphic/GraphicPropertyPanel.hxx
	svx/source/sidebar/insert/InsertPropertyPanel.cxx
	svx/source/sidebar/insert/InsertPropertyPanel.hxx
	svx/source/sidebar/line/LinePropertyPanel.hxx
	svx/source/sidebar/line/LineWidthControl.cxx
	svx/source/sidebar/line/LineWidthControl.hxx
	svx/source/sidebar/line/LineWidthValueSet.hxx
	svx/source/sidebar/paragraph/ParaPropertyPanel.hxx
	svx/source/sidebar/possize/SidebarDialControl.cxx
	svx/source/sidebar/text/TextCharacterSpacingPopup.hxx
	svx/source/sidebar/text/TextPropertyPanel.hxx
	svx/source/sidebar/tools/PopupContainer.cxx
	svx/source/sidebar/tools/PopupControl.cxx
	svx/source/sidebar/tools/ValueSetWithTextControl.cxx
	svx/source/svdraw/svdfmtf.hxx
	svx/source/svdraw/svdibrow.cxx
	svx/source/tbxctrls/colrctrl.cxx
	svx/source/tbxctrls/tbcontrl.cxx
	sw/source/ui/dbui/mmaddressblockpage.cxx
	sw/source/ui/dialog/uiregionsw.cxx
	sw/source/ui/index/cnttab.cxx
	sw/source/uibase/inc/drpcps.hxx
	sw/source/uibase/sidebar/PageColumnControl.hxx
	sw/source/uibase/sidebar/PageMarginControl.hxx
	sw/source/uibase/sidebar/PageOrientationControl.hxx
	sw/source/uibase/sidebar/PagePropertyPanel.hxx
	sw/source/uibase/sidebar/PageSizeControl.hxx
	sw/source/uibase/uiview/view2.cxx
	sw/source/uibase/utlui/navipi.cxx
	vcl/inc/svdata.hxx
	vcl/source/control/combobox.cxx
	vcl/source/control/lstbox.cxx
	vcl/source/window/dockwin.cxx
	vcl/source/window/winproc.cxx

Change-Id: I056cf3026ff17d65cca0b6e6588bda4a88fa8d95
2015-04-28 15:08:48 +01:00
Stephan Bergmann
6cb8d552eb loplugin:simplifybool
Change-Id: I77d80494ab99b4cd70f623798389f8dc35772d8a
2015-04-24 12:36:20 +02:00
Stephan Bergmann
2240118177 Improved loplugin:literaltoboolconversion looking into cond. exprs.
...automatic rewriter fixes

Change-Id: I6b04ca80f08f8a71ff94e309fd52f44d736751ee
2015-04-23 18:39:07 +02:00
Michael Meeks
89ec9424b2 Fix a number of boost::unique_ptr errors.
Audit for this problem in:
	"vclwidget: change all vcl::window fields to be wrapped in VclPtr"

Change-Id: I6e57f078364a7fd3fd4e61c748d7af843458758e
2015-04-22 21:13:50 +01:00
Noel Grandin
321d924f15 convert HIB_ constants to scoped enum
Change-Id: I6fa3ecde4a1c5f9c7e6e1dcd22250cba065933e3
2015-04-22 10:28:40 +02:00
Noel Grandin
ed54799117 convert EBBF_ constants to scoped enum
Change-Id: I6f281001a96ebfbca20f3e8dd3423945e119eef0
2015-04-22 10:28:39 +02:00
Noel Grandin
0578aa4de2 convert BROWSER_ constants to scoped enum
and fix a couple of places where it was mixing these flags up with the
WinBits flags and calling the wrong constructor.

Change-Id: I65c66bdd5a263e2f1db179c853f3f00e9ac7659e
2015-04-22 10:28:39 +02:00
Matthew Nicholls
a1a25f4c6c tdf#88710 Cleanup after removing dbtoolsclient
Removes "virtualdbtools" and its implementation under "simpledbt", which are
mostly wrappers around various dbtools functions and classes, previously aiding
the now removed dynamic loading logic.

Removes IDataAccessTools, IDataAccessTypeConversion and IDataAccessToolsFactory
interfaces and their accompanying implementations which are completely unused.

Removes IDataAccessCharSet (implemented by ODataAccessCharSet) and moves the
implementation into a function which replaces ODataAccessCharsetHelper.

Removes ISQLParseNode and ISQLParser and their implementation in
OSimpleParseNode and OSimpleSQLParser, which simply wrap around OSQLParseNode
and OSQLParser respectively. To avoid including "sqlbison.hxx" unnecessarily,
includes to "sqlbison.hxx" are now only used where needed.

Change-Id: Id882dfbf43514d84a1eaffc1f916d627830c8cd6
Reviewed-on: https://gerrit.libreoffice.org/15450
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: David Tardon <dtardon@redhat.com>
2015-04-22 07:25:17 +00:00
Caolán McNamara
2bf87e1c9d Visbile->Visible
Change-Id: I7f26d81c83ff3eee7dfbdc3b9c76592bb152e130
2015-04-21 14:19:04 +01:00
Michaël Lefèvre
2e5af8d69f CppCheck cleaning : avoid unnecessary affectation
Change-Id: I3803c5898f94e2786ba6fa464b503f36f5a449ab
Reviewed-on: https://gerrit.libreoffice.org/14847
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
2015-04-21 13:13:47 +00:00
Michael Meeks
f12488405c dbaccess: convert new to ::Create.
Also convert svtools' WizardShell::createPage.

Change-Id: I09bd40ef4748aa2de7b49eeefc95be06b545ea05
2015-04-20 15:13:23 +01:00
Noel Grandin
cb516fafbb svx: convert new to ::Create.
Change-Id: Idbcc64e883b79081c7a6399e1aed8a6b20035f69
2015-04-17 17:05:46 +02:00
Noel Grandin
71b809959b remove unnecessary use of void in function declarations
ie.
    void f(void);
becomes
    void f();

I used the following command to make the changes:

  git grep -lP '\(\s*void\s*\)' -- *.cxx \
    | xargs perl -pi -w -e 's/(\w+)\s*\(\s*void\s*\)/$1\(\)/g;'

and ran it for both .cxx and .hxx files.

Change-Id: I314a1b56e9c14d10726e32841736b0ad5eef8ddd
2015-04-15 11:47:12 +02:00
Michael Meeks
5245021a80 Explicit disposeOnce instead of transient wrappers.
Change-Id: I578aa360c9923abd3fc516865896a004f377375b
audit: "vclwidget: check for calling delete on subclasses of vcl::Window"
2015-04-13 15:49:24 +01:00