aboutsummaryrefslogtreecommitdiffstats
path: root/Source/TablesList.m
Commit message (Collapse)AuthorAgeFilesLines
* - Rewrite field mapping table selection logic - simplified logic, no longer ↵rowanbeentje2009-11-111-4/+0
| | | | | | | | | | tied to table list selection. Much faster selection of table to import into if, eg, content view is selected. Fixes weird crashes. - No longer display views as import targets - When one import has been cancelled, still allow new imports - Improve error reporting - No longer re-sort table/view/etc names returned by TablesList as preferred order is being used for display and the default compare: reverts this
* - Fix an issue when switching databases - allow the table selection to be ↵rowanbeentje2009-11-101-0/+5
| | | | | | | cleared/reset as necessary - Move the task progress layer to a child window, which can then be faded in - smooths the visual appearance and fixes drawing artifacts
* Set keyboard shortcut for Delete button in alert dialogs to command D.avenjamin2009-11-091-3/+9
| | | | Set keyboard shortcut for Truncate button in alert dialog to command T
* Don't run the add new index sheet modally, thus blocking the main thread. ↵stuconnolly2009-11-091-1/+1
| | | | Part of issue #357. Also some refactoring.
* - Support nested task levels to allow tasks to overlaprowanbeentje2009-11-081-6/+30
| | | | | | | - Thread history loading, thus using the nested task elvels and fixing history interaction in recent builds - Thread initial database loads - Improve progress indicator slightly
* - Alter query start/stop notifications to apply to only the originating ↵rowanbeentje2009-11-051-2/+2
| | | | window, regardless of key state, by passing in and looking for the table document instance
* - Use threaded loads when switching view tabs for unloaded tablesrowanbeentje2009-11-041-1/+12
|
* - Add task support to all the main interface viewsrowanbeentje2009-11-041-215/+238
| | | | | | | | - Improve task support on previously supported views - Use a threaded task load for all initial table loads - Support threaded task loads for table content loads, reloads, sorts, and filters - Improve upon previous threaded task loads by minimising view updates and supporting updates of the existing data arrays where valid
* - When performing threaded data loads, no longer disable the tables and ↵rowanbeentje2009-10-271-2/+16
| | | | instead prevent selection/editing/sorting in code; this prevents the tableviews from going grey during the load and minimises flicker and loss of focussed elements.
* - Set up TableSource to respond to task notifications to prepare for ↵rowanbeentje2009-10-271-0/+6
| | | | | | | threaded queries - Alter task notifications to pass the TableDocument as the notification object so that only the current window responds to the notification, allowing other windows to be fully used while a window is performing a task
* Don't run the add new database sheet modally, thus blocking the main thread. ↵stuconnolly2009-10-261-1/+0
| | | | Part of issue #357.
* Interface labeling.stuconnolly2009-10-211-1/+1
|
* Initial work on threaded task, with an implementation of Table Content view ↵rowanbeentje2009-10-201-0/+36
| | | | | | | | | data loading: - Removal of AMIndeterminateProgressIndicatorCell, and addition of a custom fork of YRKSpinningProgressIndicator which fixes bugs, adds threaded drawing, and adds a determinate mode. - Addition of a task system within TableDocument, triggering display of a large central progress indicator and stopping the window from being interacted with in any way that would cause a query while the task is running. - Add threaded TableContent content fetching, including use of the new task system and determinate progress bar; make fixes to improve threading stability and interaction.
* Replace the use of hard coded preference keys with constants to prevent ↵stuconnolly2009-10-171-3/+4
| | | | issues such as the one fixed in revision 1419. All future preference usage should be done so using these constants.
* When duplicating table, but not its contents strip out any occurrence of a ↵stuconnolly2009-10-021-1/+8
| | | | present AUTO_INCREMENT value. Fixes issue #391.
* When duplicating a table strip out the names of any occurrences of InnoDB ↵stuconnolly2009-10-021-0/+7
| | | | foreign key references as the names must be unique. MySQL will create the new names based on the new table name. Fixes issue #398.
* • first implementation of a Content Filter EditorBibiko2009-10-011-5/+5
| | | | | | | | | | | | | | - user-defined content filter can be saved globally (Prefs) or in SPF files - BETA - further tests are needed due to complexity - SPQueryController now handles the local user-defined content filters - tooltips are now generated automatically if not defined explicitly (incl. if $BINARY placeholder was used) • if user added local query favorites or content filters to an Untitled document and s/he wants to close it the standard sheet will be displayed (Don't Save - Cancel - Save) - due to that changed old [TableDocument displayName] to 'displaySPName' to be conform with Cocoa • changed behavior while importing query favorites - now they will append at the list (not inserted after selected row - makes more sense) • introduced to history filter dict the key 'menuLabel' which will be set to [TableContent tableFilterString] for displaying the history menu title and simplified the SPHistoryController logic for that • minor code changes
* - When adding tables, use standard selection update methods rather than ↵rowanbeentje2009-09-281-30/+2
| | | | custom (and partial) code; fixes issues of showing old columns/data from the previous table when creating new tables.
* • fixed issue if after displaying a sheet for renaming/duplicating/adding ↵Bibiko2009-09-241-11/+47
| | | | | | | | | | a table an error sheet will be ordered out (order out the first sheet explicitly in beforehand) - this solves issue 418 • improved table name check for renaming/duplicating/adding a table - it checks for trailing white spaces since 'foo ' is not valid - it checks for length - it checks whether the entered table name doesn't occur as table/view name in the current database (case-insensitively and only while entering the name in sheets)
* • fixed (hopefully) : While adding all procedures and functions do check ↵Bibiko2009-09-031-1/+3
| | | | for mysql errors - if information_schema is not accessible for some reasons omit adding procedures and functions silently
* - Fix exception/hang when an error occurs when deleting a table or tablesrowanbeentje2009-09-031-20/+36
| | | | | | - Improve error messages encountered when deleting multiple tables, asking whether to stop or continue; also now shows all errors, not just the last (if it showed any!) - Fix various exceptions caused by the table list attempting to redraw while the underlying data is being changed
* • simplified and unified the issue to set the title of a tableWindowBibiko2009-09-021-13/+10
| | | | | | | | | | | | | | - everything will be configured in [TableDocument displayName] - to update the title call [TableDocument setTitle:[TableDocument displayName]] - this removes dozens of lines • first steps to support more the document-based approach ( a document is nothing else than a connection with view properties and preferences ) - renamed/added/changed in Main Menu items into "New", "Open", "Save", and "Save As" - if user opened a spf file -> fileURL will be set - "Save" will save the current connection/view data according to the "Save As" setting - ie if one saved a doc with do not "Remember window state" - "Save" won't save the window state; to enable this hit "Save As" [this works for encrypted file data as well] - if the current doc was opened from file and the user closes it or quits the entire app all connection/document-based preferences (up to now query favs and history) will be updated silently [not yet implemented fully in CustomQuery] [works for encrypted file as well] • delete saveSPFAccessory view from DBView since it was outsourced • fixed some issues for the NSSecureTextField in the Save accessory panel (but still a warning appears)
* • further improvements to restore a SP session from spf fileBibiko2009-08-231-6/+6
|
* - The add, rename and copy table sheets should not block the main thread ↵stuconnolly2009-08-181-463/+504
| | | | | | | | (part of issue #357). - Improve the consistency of destructive confirmation dialogs by making the remove field and index dialogs default button 'Cancel' with a key equivalent of return. - Disable the remove field button when the currently selected table only has one field, removing the need for the extra check (and subsequent dialog) when the user attempts to remove a field.
* Fix some MainMenu references by index.mltownsend2009-08-111-1/+1
|
* - Fix some small memory leaks when changing tablesrowanbeentje2009-08-041-0/+3
| | | | | - Fix the history navigation to correctly switch across databases without invalid history states
* • button tooltip for "Show / Hide Table Information" toggles according to ↵Bibiko2009-08-021-0/+4
| | | | | | | its status • after editing a field in Custom Query table scroll to last selected row after data refreshing - (TODO: should be improved in near future)
* - Fix an errant NSLog in TableSourcerowanbeentje2009-08-011-0/+3
| | | | | | - Improve and make consistent state saving in TableContent; now saves filters and scroll position mor reliably on refresh/edit, and supports remembering and restoring which rows were selected - Significantly improve table history - only create entries for tables switches or filters, only remember 50 items, and save view/filters/scroll position/selections in table content view
* - Add an initial barebones version of the history controller, with a basic ↵rowanbeentje2009-07-301-0/+2
| | | | toolbar item to navigate backwards and forwards. TBC!
* - Added Splitview delegate method to hide the drag handle on the Table Info ↵avenjamin2009-07-291-0/+19
| | | | pane and Filter view.
* - Fix "endSheet:returnCode: requires a non-nil sheet" log lines during importsrowanbeentje2009-07-281-0/+6
| | | | | | - Enable threaded animation for import/export progress bars as it has minimal overhead and looks nicer - Fix exceptions caused by tablesList drawing during imports
* - Clear selection if user is filtering table list with multiple tables ↵rowanbeentje2009-07-281-4/+7
| | | | selected, to avoid issues
* Improve TablesList significantly:rowanbeentje2009-07-281-365/+652
| | | | | | | | - If there are twenty or more tables, show a table quicksearch/filter at the top of the list, and update the rest of the code to match. This addresses issue #178. - Select tables and views alphabetically by user's current locale (instead of default MySQL "A B C a b c") - When adding or duplicating tables, insert them at the correct point - Fix a number of minor display bugs caused by incorrect interaction with the tables list caches
* - Tweak table information panel to show scrollbars if it's resized to a ↵rowanbeentje2009-07-261-0/+25
| | | | | | | | position that would hide content - Store collapse state of table information panel in preferences - Apply a double fix for BWSplitView/NSSplitView+BWAnchoredButtonBar not informing delegates of resizes - correctly inform original BWSplitView delegates of resizes, and allow BWAnchoredButtonBar registered delegates to recieve the original split view resize notifications. This fixes database menu resizing in synch with splitview resizing for improved/consistent look and feel.
* Merge framework integration branch back to trunk. Summary of changes:stuconnolly2009-07-211-9/+7
| | | | | | | | | | | | | | | - Includes all custom code from subclasses CMMCPConnection and CMMCPResult, meaning they have subsequently been removed from the project. - All previous Sequel Pro specific code in the above subclasses has been removed in favour of the delegate (currently set to TableDocumet) informing the framework of such information. - All references to CMMCPConnection and CMMCPResult have subsequently been changed to MCPConnection and MCPResult. - Framework includes MySQL 5.1.36 client libraries and source headers. - Framework is now built as a 4-way (32/64 bit, i386/PPC arch) binary. - All import references to <MCPKit_bundled/MCPKit_bundled.h> have been changed to <MCPKit/MCPKit.h>. - New script 'build-mysql-client.sh' can be used to build the MySQL client libraries from the MySQL source. See the script's header for a list of available options or run it with no arguments to display it's usage. Note that there are still a few changes to be made to the framework with regard to removing Sequel Pro specific calls to the delegate. These however can be made later on as they have no effect on functionality and are merely design changes. Also, note that any future development done on the framework should be made to be as 'generic' as possible, with no Sequel Pro specific references. This should allow the framework to be integrated into another project without the need for SP specific code.
* - When selecting tables - eg from a foreign key link - fall back to a case ↵rowanbeentje2009-07-181-1/+10
| | | | insensitive match if a full match fails, as MySQL can return foreign key references as lowercase rather than actual case
* Add the ability to navigate between tables via foreign key relationships, ↵rowanbeentje2009-07-181-0/+24
| | | | | | | | | addressing the first part of #209: - For the first column linked by each foreign key, display a link arrow within the table cell - When clicking on the link arrow, select the reference table and set the table filters to select the clicked value - Also uses the table cell subclass to allow the entire cell to be editable, not just the contained text (addresses #250)
* • fix for completion in CustomQuery editorBibiko2009-07-141-0/+72
| | | | | | | - now the gathering of suggestions does not query the MySQL connection, instead it uses the TableList/TableDocument tableView data as a kind of cache - this approach should improve the speed for slow server connections TODO: auto-update for TableList and Database List resp. (it could happen that an other user changed the name of a table/db meanwhile)
* Restore the position of the buttons on the remove table and truncate table ↵stuconnolly2009-07-021-4/+16
| | | | confirmation dialogs, but change the cancel button to the have key equivalent of return.
* When displaying the add new table sheet use SPDatabaseData to get the ↵stuconnolly2009-07-011-6/+5
| | | | available storage engines instead of the information_schema.engines table, which doesn't exist in versions other than MySQL 5.
* - Make changes to the table structure flush the appropriate table data cachesrowanbeentje2009-06-241-0/+8
| | | | | | - SPTableData's columnWithName: now updates caches as necessary to avoid issues - Mark the extended table info view (particularly the CREATE TABLE syntax) as requiring update following table structure changes
* • added separate Menu "Context Menu (Table List)" to DBView.xibBibiko2009-06-241-1/+55
| | | | | | - it's used for the contextual menu for the Table List • fixed: contextual menu in Table List
* Implement some of the points suggested in issue #309:stuconnolly2009-06-241-14/+14
| | | | | | - All menu items which show a panel of some kind before completing the action need to have "..." after the menu item name. - All menu items which do something destructive (drop table, truncate table) need to default to the CANCEL button in their alert message.
* • tried to unify the displaying of error messages (mainly converted them ↵Bibiko2009-06-241-7/+13
| | | | | | | | into sheets) • changed the alert for "Truncate table" - "Are you sure you want to delete ALL table records in the..." • added BWToolkitFramework copyright notice to credits.rtf
* • added to SPArrayAdditions.h: NSArrayObjectAtIndex() inline functionBibiko2009-06-181-8/+9
| | | | | | | | | - id o = NSArrayObjectAtIndex(anArray, index) :== id o = [anArray objectAtIndex:index] - this speed up it ~3µs per call - replaced that inline function for such calls within loops to speed up them • used IMP function pointers for keepAlive calls within queryString: • set -O3 (Fastest) compiler option • allow in preference pane "Tables" to set the Limit up to 50000
* • different log message for changing max_allowed_packet for increasing it ↵Bibiko2009-06-151-0/+1
| | | | | | | | and for resetting it (a bit more transparent info) - now also check the delegate if queryGaveError: method is implemented • while adding/updating a row to the db Table Content's pane now indicates that process better via spinning wheel • after TRUNCATE TABLE reload that table content
* Implementation of enhancement #273: Allow user to truncate table by right ↵stuconnolly2009-06-151-45/+94
| | | | clicking.
* • cleaned code for the case that the user selects a view which causes a ↵Bibiko2009-06-101-3/+10
| | | | | | | | | MySQL error while retrieving data - [SPTableData tableEncoding] returns nil if no encoding can be found - [TableList tableViewSelectionDidChange:] checks in beforehand for a valid table encoding; this avoids to get the same MySQL error message twice and cleaned the structure view • if a MySQL error occurred while retrieving table data for the content view set the content view to a defined and clean status • bound TableContent's filterButton to DBView.xib to disable it if an error occurred (otherwise the status bar shows unexplainable results )
* • reload table list, database pull-down menu according to user's ↵Bibiko2009-06-051-6/+4
| | | | | | | | | statements in the Custom Query editor if necessary - if statement begins with: use, create, alter, rename, drop • reload table list, database pull-down menu according to imported statements • sped up "Import MySQL Dump" • fixed some tiny issues of the last commit
* Fixed some memory leaks found using llvm/clang. There are still some to fixbamse162009-06-051-5/+10
|
7' href='#n1417'>1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918 1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943 1944 1945 1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 1956 1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971 1972 1973 1974 1975 1976 1977 1978 1979 1980 1981 1982 1983 1984 1985 1986 1987 1988 1989 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2027 2028 2029 2030 2031 2032 2033 2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 2088 2089 2090 2091 2092 2093 2094 2095 2096 2097 2098 2099 2100 2101 2102 2103 2104 2105 2106 2107 2108 2109 2110 2111 2112 2113 2114 2115 2116 2117 2118 2119 2120 2121 2122 2123 2124 2125 2126 2127 2128 2129 2130 2131 2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 2146 2147