1d1766043SAndrew Rist/************************************************************** 2cdf0e10cSrcweir * 3d1766043SAndrew Rist * Licensed to the Apache Software Foundation (ASF) under one 4d1766043SAndrew Rist * or more contributor license agreements. See the NOTICE file 5d1766043SAndrew Rist * distributed with this work for additional information 6d1766043SAndrew Rist * regarding copyright ownership. The ASF licenses this file 7d1766043SAndrew Rist * to you under the Apache License, Version 2.0 (the 8d1766043SAndrew Rist * "License"); you may not use this file except in compliance 9d1766043SAndrew Rist * with the License. You may obtain a copy of the License at 10cdf0e10cSrcweir * 11d1766043SAndrew Rist * http://www.apache.org/licenses/LICENSE-2.0 12cdf0e10cSrcweir * 13d1766043SAndrew Rist * Unless required by applicable law or agreed to in writing, 14d1766043SAndrew Rist * software distributed under the License is distributed on an 15d1766043SAndrew Rist * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16d1766043SAndrew Rist * KIND, either express or implied. See the License for the 17d1766043SAndrew Rist * specific language governing permissions and limitations 18d1766043SAndrew Rist * under the License. 19cdf0e10cSrcweir * 20d1766043SAndrew Rist *************************************************************/ 21d1766043SAndrew Rist 22d1766043SAndrew Rist 23cdf0e10cSrcweir 24cdf0e10cSrcweir#ifndef __com_sun_star_form_runtime_FormFeature_idl__ 25cdf0e10cSrcweir#define __com_sun_star_form_runtime_FormFeature_idl__ 26cdf0e10cSrcweir 27cdf0e10cSrcweir//============================================================================= 28cdf0e10cSrcweir 29cdf0e10cSrcweirmodule com { module sun { module star { module form { module runtime { 30cdf0e10cSrcweir 31cdf0e10cSrcweir//============================================================================= 32cdf0e10cSrcweir 33cdf0e10cSrcweir/** specifies the operations on a user interface form, as supported by the 34cdf0e10cSrcweir <type>XFormOperations</type> interface. 35cdf0e10cSrcweir 36*96af39f7SJürgen Schmidt @since OpenOffice 2.2 37cdf0e10cSrcweir*/ 38cdf0e10cSrcweirconstants FormFeature 39cdf0e10cSrcweir{ 40cdf0e10cSrcweir /** moves the form to a record given by absolute position. 41cdf0e10cSrcweir 42cdf0e10cSrcweir <p>This operation cannot be executed without arguments. When executing it (i.e. 43cdf0e10cSrcweir when calling <member scope="com::sun::star::form::runtime">XFormOperations::executeWithArguments</member>), 44cdf0e10cSrcweir you need to specify a parameter named <em>Position</em> of type <code>long</code>, which 45cdf0e10cSrcweir denotes the position to move the form to.</p> 46cdf0e10cSrcweir */ 47cdf0e10cSrcweir const short MoveAbsolute = 1; 48cdf0e10cSrcweir 49cdf0e10cSrcweir /** determines the number of total records in the form, 50cdf0e10cSrcweir including the potentially active insertion row. 51cdf0e10cSrcweir 52cdf0e10cSrcweir <p>This is not strictly an operation you can do on a form, but rather a 53cdf0e10cSrcweir state you can retrieve (and display to the user) using the <type>XFormOperations</type>' 54cdf0e10cSrcweir respective methods.</p> 55cdf0e10cSrcweir 56cdf0e10cSrcweir <p>The state obtained here is a string, not a number. This is because in an UI 57cdf0e10cSrcweir form, the fact that the current record count is not yet known (since not all 58cdf0e10cSrcweir records have been visited, yet) is indicated by an asterik (<code>*</code>) besides 59cdf0e10cSrcweir the record count.</p> 60cdf0e10cSrcweir */ 61cdf0e10cSrcweir const short TotalRecords = 2; 62cdf0e10cSrcweir 63cdf0e10cSrcweir /// moves the form to the first record 64cdf0e10cSrcweir const short MoveToFirst = 3; 65cdf0e10cSrcweir 66cdf0e10cSrcweir /// moves the form to the record before the current record, if there is any 67cdf0e10cSrcweir const short MoveToPrevious = 4; 68cdf0e10cSrcweir 69cdf0e10cSrcweir /// moves the form to the record after the current record, if there is any 70cdf0e10cSrcweir const short MoveToNext = 5; 71cdf0e10cSrcweir 72cdf0e10cSrcweir /// moves the form to the last record 73cdf0e10cSrcweir const short MoveToLast = 6; 74cdf0e10cSrcweir 75cdf0e10cSrcweir /// moves the form to the insertion row, if privileges allow 76cdf0e10cSrcweir const short MoveToInsertRow = 7; 77cdf0e10cSrcweir 78cdf0e10cSrcweir /** saves all changes in the form's current record, including changes in the current 79cdf0e10cSrcweir control which had not yet been committed to the form 80cdf0e10cSrcweir */ 81cdf0e10cSrcweir const short SaveRecordChanges = 8; 82cdf0e10cSrcweir 83cdf0e10cSrcweir /** revertsall changes in the form's current record, including changes in the current 84cdf0e10cSrcweir control which had not yet been committed to the form 85cdf0e10cSrcweir */ 86cdf0e10cSrcweir const short UndoRecordChanges = 9; 87cdf0e10cSrcweir 88cdf0e10cSrcweir /** deletes the current record, while honoring any registered 89cdf0e10cSrcweir <type scope="com::sun::star::form">XConfirmDeleteListener</type>s 90cdf0e10cSrcweir */ 91cdf0e10cSrcweir const short DeleteRecord = 10; 92cdf0e10cSrcweir 93cdf0e10cSrcweir /// reloads the form content 94cdf0e10cSrcweir const short ReloadForm = 11; 95cdf0e10cSrcweir 96cdf0e10cSrcweir /// sorts the form ascending by the field which the active form control is bound to. 97cdf0e10cSrcweir const short SortAscending = 12; 98cdf0e10cSrcweir 99cdf0e10cSrcweir /// sorts the form descending by the field which the active form control is bound to. 100cdf0e10cSrcweir const short SortDescending = 13; 101cdf0e10cSrcweir 102cdf0e10cSrcweir /// opens a dialog which allows the user to interactively specify a form sorting order 103cdf0e10cSrcweir const short InteractiveSort = 14; 104cdf0e10cSrcweir 105cdf0e10cSrcweir /** adds a filter to the form, which is defined by the active form control and its 106cdf0e10cSrcweir current value 107cdf0e10cSrcweir 108cdf0e10cSrcweir <p>For instance, if the currently active form control is bound to a table field 109cdf0e10cSrcweir named <code>Price</code>, and currently has a value of <code>100</code>, then invoking 110cdf0e10cSrcweir the <code>AutoFilter</code> operation will put an additional filter <code>Price = 100</code> 111cdf0e10cSrcweir on the form.</p> 112cdf0e10cSrcweir */ 113cdf0e10cSrcweir const short AutoFilter = 15; 114cdf0e10cSrcweir 115cdf0e10cSrcweir /// opens a dialog which allows the user to interactively specify a form filter 116cdf0e10cSrcweir const short InteractiveFilter = 16; 117cdf0e10cSrcweir 118cdf0e10cSrcweir /** toggles the <member scope="com::sun::star::sdb">RowSet::ApplyFilter</member> property 119cdf0e10cSrcweir of a the form. 120cdf0e10cSrcweir */ 121cdf0e10cSrcweir const short ToggleApplyFilter = 17; 122cdf0e10cSrcweir 123cdf0e10cSrcweir /** removes all filter and sort criterions put on the form. 124cdf0e10cSrcweir 125cdf0e10cSrcweir <p>Note that this does not apply to criterios which are part of the form's 126cdf0e10cSrcweir data source. That is, if you bind the form to the SQL command <code>SELECT * FROM 127cdf0e10cSrcweir Articles WHERE Price > 100</code>, then the <code>Price > 100</code> filter 128cdf0e10cSrcweir will not be removed.</p> 129cdf0e10cSrcweir 130cdf0e10cSrcweir <p>Effectively, this operation resets the <member scope="com::sun::star::sdb">RowSet::Filter</member> 131cdf0e10cSrcweir and <member scope="com::sun::star::sdb">RowSet::Order</member> properties of the form.</p> 132cdf0e10cSrcweir */ 133cdf0e10cSrcweir const short RemoveFilterAndSort = 18; 134cdf0e10cSrcweir 135cdf0e10cSrcweir /** refreshs the current control 136cdf0e10cSrcweir 137cdf0e10cSrcweir <p>Basically, this means calling XRefreshable::refresh on the current control, if it supports 138cdf0e10cSrcweir this interface.</p> 139cdf0e10cSrcweir 140*96af39f7SJürgen Schmidt @since OpenOffice 3.1 141cdf0e10cSrcweir */ 142cdf0e10cSrcweir const short RefreshCurrentControl = 19; 143cdf0e10cSrcweir}; 144cdf0e10cSrcweir 145cdf0e10cSrcweir//============================================================================= 146cdf0e10cSrcweir 147cdf0e10cSrcweir}; }; }; }; }; 148cdf0e10cSrcweir 149cdf0e10cSrcweir//============================================================================= 150cdf0e10cSrcweir 151cdf0e10cSrcweir#endif 152