Skip to content

Commit

Permalink
SQLyog 13.1 GA
Browse files Browse the repository at this point in the history
  • Loading branch information
sandhyawy committed Aug 16, 2018
1 parent 4c5bc71 commit 7bdcd0c
Show file tree
Hide file tree
Showing 37 changed files with 8,406 additions and 233 deletions.
10 changes: 6 additions & 4 deletions build/SQLyogCommunity.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@
<ClCompile>
<Optimization>Disabled</Optimization>
<AdditionalIncludeDirectories>../include;../include/scintilla;../include/mysql;../include/htmlayout;../include/pcre;../include/tinyxml;../include/vld;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PreprocessorDefinitions>WIN32;_DEBUG;_WINDOWS;_WIN32_WINNT=0x501;COMMUNITY;UNICODE;_UNICODE;PCRE_STATIC;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;_CRT_NON_CONFORMING_SWPRINTFS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>WIN32;_DEBUG;_WINDOWS;_WIN32_WINNT=0x600;COMMUNITY;UNICODE;_UNICODE;PCRE_STATIC;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;_CRT_NON_CONFORMING_SWPRINTFS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<MinimalRebuild>true</MinimalRebuild>
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
Expand All @@ -108,7 +108,7 @@
<DebugInformationFormat>EditAndContinue</DebugInformationFormat>
</ClCompile>
<Link>
<AdditionalDependencies>shfolder.lib;version.lib;Ws2_32.lib;odbc32.lib;odbccp32.lib;wsock32.lib;comctl32.lib;htmlhelp.lib;wininet.lib;imm32.lib;gdiplus.lib;ole32.lib;msimg32.lib;sqlite3.lib;mariadbclient.lib;HTMLayout.lib;pcre.lib;Rpcrt4.lib;shlwapi.lib;vld.lib;winmm.lib;ssleay32MD.lib;libeay32MD.lib;%(AdditionalDependencies)</AdditionalDependencies>
<AdditionalDependencies>shfolder.lib;version.lib;Ws2_32.lib;odbc32.lib;odbccp32.lib;wsock32.lib;comctl32.lib;htmlhelp.lib;wininet.lib;imm32.lib;gdiplus.lib;ole32.lib;msimg32.lib;sqlite3.lib;mariadbclient.lib;HTMLayout.lib;pcre.lib;Rpcrt4.lib;shlwapi.lib;vld.lib;winmm.lib;ssleay32MD.lib;libeay32MD.lib;wevtapi.lib;%(AdditionalDependencies)</AdditionalDependencies>
<OutputFile>$(OutDir)$(TargetName)$(TargetExt)</OutputFile>
<IgnoreAllDefaultLibraries>false</IgnoreAllDefaultLibraries>
<IgnoreSpecificDefaultLibraries>LIBCMT;msvcrt;%(IgnoreSpecificDefaultLibraries)</IgnoreSpecificDefaultLibraries>
Expand Down Expand Up @@ -159,7 +159,7 @@
<InlineFunctionExpansion>AnySuitable</InlineFunctionExpansion>
<FavorSizeOrSpeed>Speed</FavorSizeOrSpeed>
<AdditionalIncludeDirectories>../include;../include/scintilla;../include/mysql;../include/htmlayout;../include/pcre;../include/tinyxml;../include/vld;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_WIN32_WINNT=0x501;SCI_LEXER;STATIC_BUILD;COMMUNITY;_UNICODE;UNICODE;PCRE_STATIC;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;_CRT_NON_CONFORMING_SWPRINTFS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_WIN32_WINNT=0x600;SCI_LEXER;STATIC_BUILD;COMMUNITY;_UNICODE;UNICODE;PCRE_STATIC;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;_CRT_NON_CONFORMING_SWPRINTFS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<StringPooling>true</StringPooling>
<ExceptionHandling>Sync</ExceptionHandling>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
Expand All @@ -171,7 +171,7 @@
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
</ClCompile>
<Link>
<AdditionalDependencies>shfolder.lib;version.lib;Ws2_32.lib;odbc32.lib;odbccp32.lib;wsock32.lib;comctl32.lib;htmlhelp.lib;wininet.lib;imm32.lib;gdiplus.lib;ole32.lib;msimg32.lib;sqlite3.lib;mariadbclient.lib;HTMLayout.lib;pcre.lib;Rpcrt4.lib;shlwapi.lib;vld.lib;winmm.lib;%(AdditionalDependencies)</AdditionalDependencies>
<AdditionalDependencies>shfolder.lib;version.lib;Ws2_32.lib;odbc32.lib;odbccp32.lib;wsock32.lib;comctl32.lib;htmlhelp.lib;wininet.lib;imm32.lib;gdiplus.lib;ole32.lib;msimg32.lib;sqlite3.lib;mariadbclient.lib;HTMLayout.lib;pcre.lib;Rpcrt4.lib;shlwapi.lib;vld.lib;winmm.lib;wevtapi.lib;%(AdditionalDependencies)</AdditionalDependencies>
<OutputFile>$(OutDir)$(TargetName)$(TargetExt)</OutputFile>
<IgnoreAllDefaultLibraries>false</IgnoreAllDefaultLibraries>
<IgnoreSpecificDefaultLibraries>LIBCD;msvcrt;%(IgnoreSpecificDefaultLibraries)</IgnoreSpecificDefaultLibraries>
Expand Down Expand Up @@ -308,6 +308,7 @@
<ClCompile Include="..\src\ImportBatch.cpp" />
<ClCompile Include="..\src\ImportData.cpp" />
<ClCompile Include="..\src\ImportFromSQL.cpp" />
<ClCompile Include="..\src\jsoncpp.cpp" />
<ClCompile Include="..\src\KeyShortCuts.cpp" />
<ClCompile Include="..\src\L10n.cpp" />
<ClCompile Include="..\src\L10nText.cpp" />
Expand Down Expand Up @@ -451,6 +452,7 @@
<ClInclude Include="..\include\ImportBatch.h" />
<ClInclude Include="..\include\ImportFromSQL.h" />
<ClInclude Include="..\include\Include.h" />
<ClInclude Include="..\include\jsoncpp.h" />
<ClInclude Include="..\include\L10n.h" />
<ClInclude Include="..\include\L10nText.h" />
<ClInclude Include="..\include\LexHelper.h" />
Expand Down
6 changes: 6 additions & 0 deletions build/SQLyogCommunity.vcxproj.filters
Original file line number Diff line number Diff line change
Expand Up @@ -357,6 +357,9 @@
<ClCompile Include="RegisterEmail.cpp">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="..\src\jsoncpp.cpp">
<Filter>Source Files</Filter>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\include\AppInfo.h">
Expand Down Expand Up @@ -704,6 +707,9 @@
<ClInclude Include="..\include\Announcements.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="..\include\jsoncpp.h">
<Filter>Header Files</Filter>
</ClInclude>
</ItemGroup>
<ItemGroup>
<None Include="..\include\bitmaps\about.ico">
Expand Down
2 changes: 0 additions & 2 deletions include/CommonHelper.h
Original file line number Diff line number Diff line change
Expand Up @@ -109,8 +109,6 @@
//#define CPI_UTF32 12000

#define CPI_CP932 932
#define MYSQL_TYPE_JSON 245
#define FIELD_TYPE_JSON MYSQL_TYPE_JSON

enum EntType
{
Expand Down
18 changes: 17 additions & 1 deletion include/DataView.h
Original file line number Diff line number Diff line change
Expand Up @@ -392,6 +392,15 @@ class EnumListElem : public wyElem
wyString m_str;
};

// abstract interface to be used as a callback interface for DataView. Any clients can construct this with
// non null interface to DataView, and are responsible for implementing that interface which gives the complete
// live query used at that time. null implies they dont need that.
class IQueryBuilder
{
public:
virtual void GetQuery(wyString& query) = 0;
};

//Class represents the view. This is an abstact class. You need to derive your own class from this and implement the methods
class DataView
{
Expand All @@ -405,8 +414,9 @@ class DataView
/**
@param wnd : IN MDI window pointer
@param hwndparent : IN handle to parent window
@param queryBuilder : IN IQueryBuilder interface supplied from derived class
*/
DataView(MDIWindow* wnd, HWND hwndparent);
DataView(MDIWindow* wnd, HWND hwndparent, IQueryBuilder* queryBuilder);

///Destrouctor. Has to be virtual to avoid memory leak
virtual ~DataView();
Expand Down Expand Up @@ -1859,6 +1869,12 @@ class DataView

//Padding window
HWND m_hwndpadding;

// IQueryBuilder interface
IQueryBuilder* m_querybuilder;

// backtick string can be used across multiple methods. But reinit them from .ini
wyChar* m_backtick;
};

#endif
14 changes: 13 additions & 1 deletion include/SortAndFilter.h
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ enum ThreadAction;
class MySQLRowExArray;
enum ThreadExecStatus;
enum ArrayAction;
class IQueryBuilder;

//Filter type enumeration
enum FilterType
Expand Down Expand Up @@ -144,6 +145,13 @@ class SortAndFilter
*/
wyBool InitDialog();

/// Initializes the main dlg procedure
/**
@param hwndparent: IN Window handle
@returns void
*/
void OnWMInitdlgValues(HWND hwnd);

///Function to reset sort
/**
@returns void
Expand Down Expand Up @@ -185,10 +193,11 @@ class SortAndFilter
@param datalen : IN cell data length
@param col : IN selected column, can be -1
@param hwndparent : IN handle to the parent window if you are invoking custom filter, can be NULL otherwise
@param querybuilder : IN queryBuilder interface
@param prect : IN rectangle with respect to which the dialog box to be positioned, can be NULL if the command is not custom filter
@returns wyTrue on success else wyFalse
*/
wyBool BeginFilter(wyInt32 command, wyChar* data, wyUInt32 datalen, wyInt32 col, HWND hwndparent = NULL, RECT* prect = NULL);
wyBool BeginFilter(wyInt32 command, wyChar* data, wyUInt32 datalen, wyInt32 col, HWND hwndparent = NULL, IQueryBuilder* querybuilder = NULL, RECT* prect = NULL);

///Function finishes the filter operation. This includes copying any new filter applied to the current filter, or canceling it
/**
Expand Down Expand Up @@ -443,6 +452,9 @@ class SortAndFilter
wyString m_currfilterstring;

wyBool m_isfilteronnull;

// IQueryBuilder interface
IQueryBuilder* m_querybuilder;
};

#endif
3 changes: 3 additions & 0 deletions include/TabFields.h
Original file line number Diff line number Diff line change
Expand Up @@ -190,6 +190,9 @@ class TabFields

/// Persistence class object pointer
Persist *m_p;

// backtick string from preferences, either empty or quote
wyChar* m_backtick;

/// intializes m_mysql, m_tunnel and calls CreateGrid()
/**
Expand Down
12 changes: 9 additions & 3 deletions include/TabForeignKeys.h
Original file line number Diff line number Diff line change
Expand Up @@ -182,11 +182,13 @@ class TabForeignKeys

RECT m_dlgrect;


List m_controllist;
List m_controllist;

//member stores the subclassing procedure for the static control showing the gripper
WNDPROC m_gripproc;
WNDPROC m_gripproc;

// backtick string from preferences, either empty or quote
wyChar* m_backtick;

void InitStructFK(StructFK *value);

Expand Down Expand Up @@ -573,6 +575,10 @@ class TabForeignKeys
*/
void ReInitializeGrid(List *unsavedfkwrappers = NULL);

// All dervied data should be refreshed based on preferences and also display
void Refresh();
void Refresh(StructFK* fkInfo);

void SetValueToStructure(wyUInt32 row, wyUInt32 col, wyChar* data);

wyBool StructFKContainsOtherValues(StructFK *value, wyInt32 col);
Expand Down
12 changes: 9 additions & 3 deletions include/TabIndexes.h
Original file line number Diff line number Diff line change
Expand Up @@ -85,12 +85,14 @@ class TabIndexes
wyInt32 m_lastclickindgrid;
wyInt32 m_lastclickdlggrid;

RECT m_wndrect;
RECT m_wndrect;

RECT m_dlgrect;


List m_controllist;
List m_controllist;

// backtick string from preferences, either empty or quote
wyChar* m_backtick;

/// Constructor
TabIndexes(HWND hwndparent, TableTabInterfaceTabMgmt* ptabmgmt);
Expand Down Expand Up @@ -153,6 +155,10 @@ class TabIndexes

void ResizeColumnsDialog(HWND hwnd, LPARAM lParam);

// All dervied data should be refreshed based on preferences and also display
void Refresh();
void Refresh(IndexInfo *indexInfo);

/// Shows the Dialog-box if the grid cell on which mouse is clicked is INDEXCOLUMNS
/**
@returns void
Expand Down
4 changes: 4 additions & 0 deletions include/TabModule.h
Original file line number Diff line number Diff line change
Expand Up @@ -301,6 +301,10 @@ class TabModule
*/
void SetBackQuotesOption();

// Will regenerate and refresh all names, etc. which can be affected by preferences and sql previews if needed to
// apply any change in preferences etc
void Refresh();

/// Handles the checking or unchecking the Menu item 'text or grid'
/**
@param pcquerywnd : IN Query window pointer
Expand Down
2 changes: 1 addition & 1 deletion include/TableTabInterface.h
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ class TableTabInterface : public TabTypes
HBRUSH m_objbkcolor;

wyBool m_isbuffereddraw;

TableTabInterface(HWND hwnd, wyBool open_in_dialog, wyBool isaltertable, wyInt32 setfocustotab);

~TableTabInterface();
Expand Down
8 changes: 7 additions & 1 deletion include/TableView.h
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ class MySQLTableDataEx : public MySQLDataEx
};

//Class representing table view
class TableView : public DataView
class TableView : public DataView, public IQueryBuilder
{
public:
///Constuctor
Expand Down Expand Up @@ -95,6 +95,12 @@ class TableView : public DataView
@returns void
*/
void ResetToolBarButtons();

/// IQueryBuilder implementation
/**
@returns void. But caller needs to destroy query.(they own it)
*/
void GetQuery(wyString& query);

protected:
///Function to create toolbars and additional controls
Expand Down
Loading

0 comments on commit 7bdcd0c

Please sign in to comment.